Taking into consideration the runs test proposed by Knuth given a sample of pseudo-random numbers to test independence, and looking at this example:
X = (5,4,1,7,2,3,6), which yields
S = (0,0,1,0,1,1)
I'm a bit confused if:
X = (5,4,1,**1**,2,3,6), would yield
S = (0,0,1,**1**,1,1) ... call it option #1 or yield
S = (0,0,1,**0**,1,1) ... call it option #2
...and for the case of:
X = (5,**5**,1,7,2,3,6), should it yield
S = (**0**,0,1,0,1,1) ...call it option #1 or
S = (**1**,0,1,0,1,1) ...call it option #2
So what is it in the first and second cases and why?