Learn R Programming

cwhmisc (version 3.0)

shapiro.wilk.test: Shapiro-Wilk Normality Test

Description

Performs the Shapiro-Wilk test for normality.

Usage

shapiro.wilk.test(x)

Arguments

x
a numeric vector of data values, the number of which must be between 3 and 5000. Missing values are allowed.

Value

  • A list containing the following components:
  • Wthe value of the Shapiro-Wilk statistic.
  • nlength(x)
  • pthe p-value for the test.

See Also

shapiro.test of {ctest}

Examples

Run this code
shapiro.wilk.test(rnorm(100, mean = 5, sd = 3))
  shapiro.wilk.test(runif(100, min = 2, max = 4))

Run the code above in your browser using DataLab