shapiro.wilk.test: Shapiro-Wilk Normality Test

Description Usage Arguments Value Author(s) See Also Examples

Description

Performs the Shapiro-Wilk test for normality.

Usage

1

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:

W

the value of the Shapiro-Wilk statistic.

n

length(x)

p

the p-value for the test.

Author(s)

??

See Also

shapiro.test

Examples

1
2
  shapiro.wilk.test(rnorm(100, mean = 5, sd = 3))  # $p 0.169547
  shapiro.wilk.test(runif(100, min = 2, max = 4))  # $p 6.09393e-06

Example output

Loading required package: lattice
Loading required package: grid
$W
[1] 0.9812551

$n
[1] 100

$p
[1] 0.5937473

$W
[1] 0.9265778

$n
[1] 100

$p
[1] 8.487354e-06

cwhmisc documentation built on May 1, 2019, 7:55 p.m.