Computes Levene's test statistic and associated probability.
The statistic is calculated as follows. W=N−kk−1∑ki=1Ni(Zi.−Z..)2∑ki=1∑nij=1(Zij−Zi.)2
Where: Zij=|Xij−¯Xi.| Zi.=1nini∑j=1Zij Z..=1Nk∑i=1ni∑j=1Zij
As the test statistic is approximately F-distributed, the F-distribution is used to calculate the probability term.
See Also
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_container), | intent(in), | dimension(:) | :: | x |
The arrays of data to analyze. |
|
real(kind=real64), | intent(out) | :: | stat |
The Bartlett's test statistic. |
||
real(kind=real64), | intent(out) | :: | p |
The probability value that the variances of each data set are equivalent. A low p-value, less than some significance level, indicates a non-equivalance of variances. |
||
class(errors), | intent(inout), | optional, | target | :: | err |