Performs D'Agostino normality tests based on skewness, kurtosis, and an omnibus test.

dagostinoTest(x)

Arguments

x

a non-empty numeric vector of data

Details

The implementation is taken from Zvara2008 (appendix A.4.1).

Value

Data frame having the results of the skewness, kurtosis, and omnibus tests in columns, and the test statistics and P-values in rows.

References

DAgostino, Ralph B.; Albert Belanger; Ralph B. DAgostino, Jr (1990). A suggestion for using powerful and informative tests of normality. The American Statistician 44 (4): 316-321. JSTOR 2684359.

Karel Zv\'ara: Regrese, Matfyzpress Praha 2008

Examples

dagostinoTest(rnorm(100, mean = 5, sd = 3))
#> skewness kurtosis omnibus #> statistics -1.1085391 -0.2617613 1.2973779 #> p-value 0.2676291 0.7935055 0.5227307
dagostinoTest(runif(100, min = 2, max = 4))
#> skewness kurtosis omnibus #> statistics -0.6351785 -8.023750e+00 6.478401e+01 #> p-value 0.5253120 1.110223e-15 8.548717e-15