2
Does anyone know of a normality test that can be estimated (in R) for samples between 12 to 15,000 observations?
The Shapiro.test should have sample size between 3 and 5000, not apply to my sample.
2
Does anyone know of a normality test that can be estimated (in R) for samples between 12 to 15,000 observations?
The Shapiro.test should have sample size between 3 and 5000, not apply to my sample.
1
You can use the Anderson-Darling
Install the package nortest
and rotate:
library(nortest)
ad.test(rnorm(5001))
# Anderson-Darling normality test
#
# data: rnorm(5001)
# A = 0.2826, p-value = 0.6359
ad.test(runif(5001))
# Anderson-Darling normality test
#
# data: runif(5001)
# A = 65.183, p-value < 2.2e-16
Here has a good explanation of why there are limitations regarding sample size. And also strong opinions of why not use these tests.
1
Since there are criticisms of normality inspection using formal tests, an alternative is to do graphical inspection by histogram and see if the bell shape occurs in the resulting figure. The hist(data) command does this. Search for images of histograms normal distribution and use them as reference. If your histogram doesn’t have bell shape, try data transformations and redo the histogram.
Browser other questions tagged r
You are not signed in. Login or sign up in order to post.
Thank you, Daniel!
– Naomi