ShapiroWilkWTest - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.
Our website is currently undergoing maintenance, which may result in occasional errors while browsing. We apologize for any inconvenience this may cause and are working swiftly to restore full functionality. Thank you for your patience.

Online Help

All Products    Maple    MapleSim


Statistics

  

ShapiroWilkWTest

  

apply Shapiro and Wilk's W-test for normality of a sample

 

Calling Sequence

Parameters

Description

Options

Notes

Examples

References

Compatibility

Calling Sequence

ShapiroWilkWTest(X, options)

Parameters

X

-

data sample

options

-

(optional) equation(s) of the form option=value where option is one of level, output, or summarize; specify options for the ShapiroWilkWTest function

Description

• 

The ShapiroWilkWTest function computes Shapiro and Wilk's W-test applied to a data set X.  This test attempts to determine how closely a given sample matches a normal distribution.

• 

The first parameter X is the data sample to use in the analysis. It should contain between 3 and 2000 data points.

Options

  

The options argument can contain one or more of the options shown below.

• 

level=float

  

This option is used to specify the level of the analysis (minimum criteria for a data set to be considered roughly normal).  By default this value is 0.05.

• 

output='report', 'statistic', 'pvalue', 'hypothesis', or list('statistic', 'pvalue', 'hypothesis')

  

This option is used to specify the desired format of the output from the function.  If 'report' is specified then a module containing all output from this test is returned.  If a single parameter name is specified other than 'report' then that quantity alone is returned.  If a list of parameter names is specified then a list containing those quantities in the specified order will be returned.

• 

summarize= 'true', 'false', 'embed'

  

This option controls the display of a printed or embedded summary for the hypothesis test. Unlike the output option, the displayed summary is not assignable output.

Notes

• 

This test generates a complete report of all calculations in the form of a userinfo message.  In order to access this report, specify infolevel[Statistics] := 1 or use the summarize option.

Examples

withStatistics:

Specify the data sample.

SSampleNormal5,2,10:

TSampleUniform4,6,10:

Calculate Shapiro and Wilk's W-test on the normally distributed sample.

ShapiroWilkWTestS,level=0.05,summarize=embed:

Null Hypothesis:

Sample drawn from a population that follows a normal distribution

Alternative Hypothesis:

Sample drawn from population that does not follow a normal distribution

Sample Size

Computed Statistic

Computed p-value

10.

0.967479

0.856736

Result:

Accepted: This statistical test does not provide enough evidence to conclude that the null hypothesis is false.

Calculate Shapiro and Wilk's W-test on the uniformly distributed sample.

ShapiroWilkWTestT,level=0.05,summarize=true:

Shapiro and Wilk's W-Test for Normality

---------------------------------------

Null Hypothesis:
Sample drawn from a population that follows a normal distribution

Alt. Hypothesis:
Sample drawn from population that does not follow a normal distribution

 

Sample Size:             10

Computed Statistic:      .832591474899495

Computed p-value:        .0351513590317937

 

Result: [Rejected]
This statistical test provides evidence that the null hypothesis is false.

References

  

Kanji, Gopal K. 100 Statistical Tests. London: SAGE Publications Ltd., 1994.

  

Sheskin, David J. Handbook of Parametric and Nonparametric Statistical Procedures. London: CRC Press, 1997.

Compatibility

• 

The Statistics[ShapiroWilkWTest] command was updated in Maple 2016.

• 

The summarize option was introduced in Maple 2016.

• 

For more information on Maple 2016 changes, see Updates in Maple 2016.

See Also

Statistics

Statistics[Computation]