knitr::opts_chunk$set(echo = TRUE)
Note: The descriptions has been taken from R.
Four x-y datasets which have the same traditional statistical properties (mean, variance, correlation, regression line, etc.), yet are quite different.
head(anscombe)
A data frame with 11 observations on 8 variables.
Variable | Meaning
-------------|---------------------------------------------------------------------------------------
x1 | X for linear relationship
x2 | X for non-linear relationship
x3 | X for outlier
x4 | X for constant
y1 | Y for linear relationship
y2 | Y for non-linear relationship
y3 | Y for outlier
y4 | Y for constant
library("lattice") dn <- c("x1-y1", "x2-y2", "x3-y3", "x4-y4") dxy<-data.frame(dataset=dn[1+(0:43)/11], x=c(anscombe$x1, anscombe$x2, anscombe$x3, anscombe$x4), y=c(anscombe$y1, anscombe$y2, anscombe$y3, anscombe$y4)) xyplot(y~x|dataset, data=dxy)
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.