Skip to content

Instantly share code, notes, and snippets.

@Sintrastes
Last active August 29, 2015 14:14
Show Gist options
  • Save Sintrastes/156a1ee918eba88095d5 to your computer and use it in GitHub Desktop.
Save Sintrastes/156a1ee918eba88095d5 to your computer and use it in GitHub Desktop.
normtest.r
# Visual single variable normality test plot
# Useful for testing normality assumptions in DOX.
normTest <- function(data){
n <- length(data)
expected <- pnorm((1:n)/(n+1))
plot(x=expected,y=sort(data),xlab="Expected Norm. Dist.",ylab="Data")
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment