Questions tagged [data-visualization]

Constructing meaningful and useful graphical representations of data. (If your question is only about how to get particular software to produce a specific effect, then it is likely not on topic here.)

Filter by
Sorted by
Tagged with
200
votes
4answers
330k views

How to interpret a QQ plot

I am working with a small dataset (21 observations) and have the following normal QQ plot in R: Seeing that the plot does not support normality, what could I infer about the underlying distribution? ...
114
votes
4answers
33k views

Assessing approximate distribution of data based on a histogram

Suppose I want to see whether my data is exponential based on a histogram (i.e. skewed to the right). Depending on how I group or bin the data, I can get wildly different histograms. One set of ...
101
votes
11answers
130k views

“Best” series of colors to use for differentiating series in publication-quality plots

Has any study been done on what are the best set of colors to use for showing multiple series on the same plot? I've just been using the defaults in matplotlib, ...
98
votes
1answer
79k views

Interpreting plot.lm()

I had a question about interpreting the graphs generated by plot(lm) in R. I was wondering if you guys could tell me how to interpret the scale-location and leverage-residual plots? Any comments ...
89
votes
4answers
180k views

How to produce a pretty plot of the results of k-means cluster analysis?

I'm using R to do K-means clustering. I'm using 14 variables to run K-means What is a pretty way to plot the results of K-means? Are there any existing implementations? Does having 14 variables ...
77
votes
4answers
25k views

How to visualize what canonical correlation analysis does (in comparison to what principal component analysis does)?

Canonical correlation analysis (CCA) is a technique related to principal component analysis (PCA). While it is easy to teach PCA or linear regression using a scatter plot (see a few thousand examples ...
76
votes
12answers
7k views

Famous statistical wins and horror stories for teaching purposes

I am designing a one year program in data analysis with a local community college. The program aims to prepare students to handle basic tasks in data analysis, visualization and summarization, ...
69
votes
3answers
133k views

How to actually plot a sample tree from randomForest::getTree()? [closed]

Anyone got library or code suggestions on how to actually plot a couple of sample trees from: getTree(rfobj, k, labelVar=TRUE) (Yes I know you're not supposed ...
68
votes
3answers
77k views

When are Log scales appropriate?

I've read that using log scales when charting/graphing is appropriate in certain circumstances, like the y-axis in a time series chart. However, I've not been able to find a definitive explanation as ...
65
votes
9answers
17k views

How to visualize what ANOVA does?

What way (ways?) is there to visually explain what is ANOVA? Any references, link(s) (R packages?) will be welcomed.
59
votes
2answers
125k views

How can I change the title of a legend in ggplot2? [closed]

I have a plot I'm making in ggplot2 to summarize data that are from a 2 x 4 x 3 celled dataset. I have been able to make panels for the 2-leveled variable using ...
58
votes
12answers
18k views

Software needed to scrape data from graph [closed]

Anybody have any experience with software (preferably free, preferably open source) that will take an image of data plotted on cartesian coordinates (a standard, everyday plot) and extract the ...
55
votes
6answers
65k views

How to determine best cutoff point and its confidence interval using ROC curve in R?

I have the data of a test that could be used to distinguish normal and tumor cells. According to ROC curve it looks good for this purpose (area under curve is 0.9): My questions are: How to ...
54
votes
7answers
54k views

Graph for relationship between two ordinal variables

What is an appropriate graph to illustrate the relationship between two ordinal variables? A few options I can think of: Scatter plot with added random jitter to stop points hiding each other. ...
54
votes
8answers
9k views

Modern successor to Exploratory Data Analysis by Tukey?

I've been reading Tukey's book "Exploratory Data Analysis". Being written in 1977, the book emphasizes paper/pencil methods. Is there a more 'modern' successor which takes into account that we can ...
53
votes
13answers
6k views

Visually interesting statistics concepts that are easy to explain

I noticed on Math Stack Exchange a terrific thread which highlighted a number of very visually interesting math concepts. I would be curious to see graphics/gifs which anyone has that very clearly ...
51
votes
9answers
52k views

Does anyone know any good open source software for visualizing data from database?

Recently I came across Tableau and tried to visualize the data from database and csv file. The user iterface enables the user to visualize time and spatial data and create plots in an instant. Such ...
50
votes
5answers
277k views

R - QQPlot: how to see whether data are normally distributed

I have plotted this after I did a Shapiro-Wilk normality test. The test showed that it is likely that the population is normally distributed. However, how to see this "behaviour" on this plot? ...
50
votes
3answers
37k views

How do I find peaks in a dataset?

If I have a data set that produces a graph such as the following, how would I algorithmically determine the x-values of the peaks shown (in this case three of them):
49
votes
17answers
11k views

What is your favorite data visualization blog?

What is the best blog on data visualization? I'm making this question a community wiki since it is highly subjective. Please limit each answer to one link. Please note the following criteria for ...
48
votes
3answers
77k views

How to visualize a fitted multiple regression model?

I am currently writing a paper with several multiple regression analyses. While visualizing univariate linear regression is easy via scatter plots, I was wondering whether there is any good way to ...
47
votes
6answers
89k views

How do I avoid overlapping labels in an R plot? [closed]

I'm trying to label a pretty simple scatterplot in R. This is what I use: plot(SI, TI) text(SI, TI, Name, pos=4, cex=0.7) The result is mediocre, as you can see (...
46
votes
1answer
10k views

How to determine whether or not the y-axis of a graph should start at zero?

One common way to "lie with data" is to use a y-axis scale that makes it seem as if changes are more significant than they really are. When I review scientific publications, or students' lab reports, ...
45
votes
10answers
6k views

How to plot trends properly

I am creating a graph to show trends in death rates (per 1000 ppl.) in different countries and the story that should come from the plot is that Germany (light blue line) is the only one whose trend is ...
45
votes
3answers
68k views

Suppression effect in regression: definition and visual explanation/depiction

What is a suppressor variable in multiple regression and what might be the ways to display suppression effect visually (its mechanics or its evidence in results)? I'd like to invite everybody who has ...
45
votes
8answers
24k views

How to do community detection in a weighted social network/graph?

I'm wondering if someone could suggest what are good starting points when it comes to performing community detection/graph partitioning/clustering on a graph that has weighted, undirected edges. The ...
44
votes
6answers
4k views

What is your favorite statistical graph?

This is a favorite of mine This example is in a humorous vein (credit goes to a former professor of mine, Steven Gortmaker), but I am also interested in graphs that you feel beautifully capture and ...
43
votes
2answers
59k views

PP-plots vs. QQ-plots

What is the difference between probability plots, PP-plots and QQ-plots when trying to analyse a fitted distribution to data?
43
votes
4answers
43k views

Would PCA work for boolean (binary) data types?

I want to reduce the dimensionality of higher order systems and capture most of the covariance on a preferably 2 dimensional or 1 dimensional field. I understand this can be done via principal ...
42
votes
4answers
82k views

How to interpret mean of Silhouette plot?

Im trying to use silhouette plot to determine the number of cluster in my dataset. Given the dataset Train , i used the following matlab code ...
40
votes
15answers
6k views

What best practices should I follow when preparing plots?

I usually make my own idiosyncratic choices when preparing plots. However, I wonder if there are any best practices for generating plots. Note: Rob's comment to an answer to this question is very ...
39
votes
4answers
18k views

For plotting with R, should I learn ggplot2 or ggvis?

For plotting with R, should I learn ggplot2 or ggvis? I don't necessarily want to learn both if one of them is superior in any regard. Why R community keeps creating new packages with overlapping ...
39
votes
8answers
31k views

Graphical data overview (summary) function in R

I'm sure I've come across a function like this in an R package before, but after extensive Googling I can't seem to find it anywhere. The function I'm thinking of produced a graphical summary for a ...
37
votes
5answers
8k views

How to visualize/understand what a neural network is doing?

Neural networks are often treated as "black boxes" due to their complex structure. This is not ideal, as it is often beneficial to have an intuitive grasp of how a model is working internally. What ...
37
votes
2answers
9k views

When is t-SNE misleading?

Quoting from one of the authors: t-Distributed Stochastic Neighbor Embedding (t-SNE) is a (prize-winning) technique for dimensionality reduction that is particularly well suited for the ...
36
votes
3answers
932 views

Experimental evidence supporting Tufte-style visualizations?

Q: Does there exist experimental evidence supporting Tufte-style, minimalist, data-speak visualizations over the chart-junked visualizations of, say, Nigel Holmes? I asked how to add chart-junk to R ...
34
votes
2answers
52k views

Interpretation of plot (glm.model)

Can anyone tell me how to interpret the 'residuals vs fitted', 'normal q-q', 'scale-location', and 'residuals vs leverage' plots? I am fitting a binomial GLM, saving it and then plotting it.
34
votes
4answers
57k views

What test can I use to compare slopes from two or more regression models?

I would like to test the difference in response of two variables to one predictor. Here is a minimal reproducible example. ...
34
votes
2answers
11k views

Is there a boxplot variant for Poisson distributed data?

I'd like to know if there is a boxplot variant adapted to Poisson distributed data (or possibly other distributions)? With a Gaussian distribution, whiskers placed at L = Q1 - 1.5 IQR and U = Q3 + 1....
34
votes
3answers
3k views

Datasets constructed for a purpose similar to that of Anscombe's quartet

I've just come across Anscombe's quartet (four datasets that have almost indistinguishable descriptive statistics but look very different when plotted) and I am curious if there are other more or less ...
34
votes
2answers
44k views

How to plot decision boundary of a k-nearest neighbor classifier from Elements of Statistical Learning?

I want to generate the plot described in the book ElemStatLearn "The Elements of Statistical Learning: Data Mining, Inference, and Prediction. Second Edition" by Trevor Hastie & Robert Tibshirani&...
33
votes
7answers
22k views

Statistical methods to more efficiently plot data when millions of points are present?

I find R can take a long time to generate plots when millions of points are present - unsurprising given that points are plotted individually. Furthermore, such plots are often too cluttered and dense ...
33
votes
6answers
18k views

Line graph has too many lines, is there a better solution?

I'm trying to graph the number of actions by users (in this case, "likes") over time. So I have "Number of actions" as my y-axis, my x-axis is time (weeks), and each line represents one user. My ...
33
votes
3answers
25k views

What distribution does my data follow?

Let us say that I have 1000 components and I have been collecting data on how many times these log a failure and each time they logged a failure, I am also keeping track of how long it took my team to ...
32
votes
3answers
12k views

Visualizing a million, PCA edition

Is it possible to visualize the output of Principal Component Analysis in ways that give more insight than just summary tables? Is it possible to do it when the number of observations is large, say ~...
32
votes
5answers
5k views

Color and line thickness recommendations for line plots

Much has been written about color blind-friendly color choices for maps, polygons, and shaded regions in general (see for example http://colorbrewer2.org). I have not been able to find ...
32
votes
2answers
83k views

Interpretation of biplots in principal components analysis

I came across this nice tutorial: A Handbook of Statistical Analyses Using R. Chapter 13. Principal Component Analysis: The Olympic Heptathlon on how to do PCA in R language. I don't understand the ...
32
votes
4answers
14k views

Optimising for Precision-Recall curves under class imbalance

I have a classification task where I have a number of predictors (one of which is the most informative), and I am using the MARS model to construct my classifier (I am interested in any simple model, ...
31
votes
4answers
4k views

Visualising many variables in one plot

I'd like to show how the values of certain variables (~ 15) change over time, but I'd also like to show how the variables differ from each other in each year. So I created this plot: But even when ...
31
votes
4answers
24k views

Why use colormap viridis over jet?

As announced in https://www.youtube.com/watch?v=xAoljeRJ3lU, Matplotlib changes the default colormap from jet to viridis. However, I don't understand it pretty well. Maybe because I'm color blind? ...

1
2 3 4 5
54