Closed gc5k closed 3 years ago
I think rollback(k)
should be rollbackColumns(k)
for k columns, right?
And what if I call rollbackColumns(3)
when I'm at the 1st column?
And what if I call
rollbackColumns(3)
when I'm at the 1st column?
rollback will be a low-frequent behavior, so, if it is called, overflow should be avoided before roll K back.
So if I call rollbackColumns(3)
when I'm at the 2nd column, I should roll back to the 1st column of the same row instead of rolling back to the last column of the last row?
So if I call
rollbackColumns(3)
when I'm at the 2nd column, I should roll back to the 1st column of the same row instead of rolling back to the last column of the last row?
then call System.exit(), if it rolls back off the table~
So if I call rollbackColumns(3) when I'm at the 2nd column, I should call System.exit() instead of rolling back to the 1st column of the same row?
Or do you want the following:
If I call rollbackColumns(3) when I'm at the 2nd column of the 2nd row, I should rollback to the 1st column of the 2nd row without calling System.exit().
If I call rollbackColumns(3) when I'm at the 2nd column of the 1st row, I should call System.exit().
So if I call rollbackColumns(3) when I'm at the 2nd column, I should call System.exit() instead of rolling back to the 1st column of the same row?
Kill it. Because it is wrong to even think of rolling back "3" when you at "2". It is rolled back when it is fully secured.
Understood, just report error and exit whether I'm in the first row.
So if I call rollbackColumns(3) when I'm at the 2nd column, I should call System.exit() instead of rolling back to the 1st column of the same row?
Kill it. Because it is wrong to even think of rolling back "3" when you at "2". It is rolled back when it is fully secured.
Another question: bed stores 4 genotypes in a byte, so if I call rollbackColumns(3)
when I'm at the 4th column and then call readNextByte()
, what does readNextByte()
return? The 1st byte or the 2nd byte?
Commit bc425e17e7bd54b7ae9bb2e547073d3ebbcce72d added BEDReader.reset
.
Two reset methods are needed. 1) reset() to the very beginning of the genotype stream 2) rollback(k) k individuals.