Merged
Conversation
I accidentally created a bug in IBDReduce at line 184-187 of the ibdreduce_v3.py.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue:
I accidentally introduced a bug in the parse_pheno function. This bug accidentally always set the phenotype column index to 1 no matter what. This bug was causing the phenotype counts to be off. It only affected trying to run IBDReduce with a phenotype matrix. This did not affect running IBDReduce with a two column phenotype file.
Fix:
I moved the phenotype_indx reassignment into the i==0 if statement so that it would only happen when reading the header line. You could also assign phenotype_indx to 1 before the with statement that opens the file but I think the if/else might be more clear in the future what is happening