I Shapiro-Wilks test and the order statistic

  • I
  • Thread starter Thread starter Mayhem
  • Start date Start date
  • Tags Tags
    Statistic Test
AI Thread Summary
In the context of the Shapiro-Wilk test, the numerator involves the order statistic, where if the data is sorted in ascending order, the notation x_(i) equals x_i. This is confirmed by the discussion, noting that x_(i) represents the ith order statistic, or the ith-smallest number in the sample. While the general rule states that x_(i) does not equal x_i, in cases where the data is pre-sorted, they can be considered equal. The participants emphasize that recognizing this special case simplifies computations, particularly when implementing the formula in programming languages like Python. This understanding aids in accurately debugging results against established calculators.
Mayhem
Messages
412
Reaction score
308
TL;DR Summary
How to interpret the order statistic in the context of SW
Given the Shapiro-Wilk test value W:
1654873563116.png

where I'm interested in the numerator. If my data is sorted in ascending order, my understanding is that $x_(i) = x_i$. Is that correct?
 
Last edited:
Mathematics news on Phys.org
Mayhem said:
Summary: How to interpret the order statistic in the context of SW

Given the Shapiro-Wilk test value W:
View attachment 302652
where I'm interested in the numerator. If my data is sorted in ascending order, my understanding is that $x_(i) = x_i$. Is that correct?
Sounds right to me. From the wiki page, https://en.wikipedia.org/wiki/Shapiro–Wilk_test:
##x_{(i)}## (with parentheses enclosing the subscript index i; not to be confused with ##x_i##) is the ith order statistic, i.e., the ith-smallest number in the sample
 
Orodruin said:
The Wiki page seems to be saying explicitly that in general ##x_{(i)} \neq x_i##.
But if the elements of the sequence are already ordered from smallest to largest, then ##x_{(i)} = x_i##.
 
Fair enough.
 
Orodruin said:
The Wiki page seems to be saying explicitly that in general ##x_{(i)} \neq x_i##.
Yes, but for computation, finding the special case where ##x_{(i)} = x_i## makes life easier, which I did, and I got the right results when debugging random samples against known calculators.
 

Similar threads

Back
Top