LeveneTest

LeveneTest[data]

tests whether the variance of data is 1.

LeveneTest[{data1,data2,}]

tests whether the variances of data1, data2, are equal.

LeveneTest[dspec,]

tests a dispersion measure against .

LeveneTest[dspec,,"property"]

returns the value of "property".

Details and Options

  • LeveneTest tests the null hypothesis against the alternative hypothesis :
  • data
    {data1,data2}
    {data1,data2,}not all equal
  • where σi2 is the population variance for datai.
  • By default, a probability value or -value is returned.
  • A small -value suggests that it is unlikely that is true.
  • The data in dspec must be univariate {x1,x2,}.
  • The argument can be any positive real number. The default value of is 1 if not specified, and ignored if the number of groups in dspec is more than 2.
  • The LeveneTest assumes the data is normally distributed and, for the two-sample case, is much less sensitive to this assumption than the FisherRatioTest.
  • LeveneTest[data,,"HypothesisTestData"] returns a HypothesisTestData object htd that can be used to extract additional test results and properties using the form htd["property"].
  • LeveneTest[data,,"property"] can be used to directly give the value of "property".
  • Properties related to the reporting of test results include:
  • "DegreesOfFreedom"the degrees of freedom used in a test
    "PValue"list of -values
    "PValueTable"formatted table of -values
    "ShortTestConclusion"a short description of the conclusion of a test
    "TestConclusion"a description of the conclusion of a test
    "TestData"list of pairs of test statistics and -values
    "TestDataTable"formatted table of -values and test statistics
    "TestStatistic"list of test statistics
    "TestStatisticTable"formatted table of test statistics
  • When one sample of size is given, the LeveneTest is equivalent to the FisherRatioTest.
  • For the -sample case {data1,data2,,datak} with datai={xi,1,xi,2,,xi,ni}, the test statistic is given by , where zi,j=Abs[xi,j-Mean[datai]], zi=Mean[{zi,1,zi,2,,zi,ni}], and z=Mean[{z1,z2,,zk}]. The test statistic is assumed to follow FRatioDistribution[k-1,sum_(i=1)^k(ni-1)] under .
  • The following options can be used:
  • AlternativeHypothesis"Unequal"the inequality for the alternative hypothesis
    SignificanceLevel0.05cutoff for diagnostics and reporting
    VerifyTestAssumptionsAutomaticset which diagnostic tests to run
  • For the LeveneTest, a cutoff is chosen such that is rejected only if . The value of used for the "TestConclusion" and "ShortTestConclusion" properties is controlled by the SignificanceLevel option. This value is also used in diagnostic tests of assumptions, including tests for normality and symmetry. By default, is set to 0.05.
  • Named settings for VerifyTestAssumptions in LeveneTest include:
  • "Normality"verify that all data is normally distributed

Examples

open allclose all

Basic Examples  (2)

Test variances from two populations for equality:

In[1]:=
Click for copyable input
In[2]:=
Click for copyable input
Out[2]=

Create a HypothesisTestData object for further property extraction:

In[3]:=
Click for copyable input
Out[3]=

Properties of the test:

In[4]:=
Click for copyable input
Out[4]=

Compare the variance of a population to a particular value:

In[1]:=
Click for copyable input
In[2]:=
Click for copyable input
Out[2]=
In[3]:=
Click for copyable input
Out[3]=

Test against the alternative hypothesis :

In[4]:=
Click for copyable input
Out[4]=

Scope  (10)

Options  (8)

Applications  (1)

Properties & Relations  (8)

Possible Issues  (3)

Neat Examples  (1)

See Also

HypothesisTestData  LocationTest  LocationEquivalenceTest  VarianceTest  VarianceEquivalenceTest  DistributionFitTest  BrownForsytheTest  ConoverTest  FisherRatioTest  SiegelTukeyTest

Introduced in 2010
(8.0)
| Updated in 2017
(11.1)