Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AgnosticSNP quality is a string and should be float #26

Closed
courcelm opened this issue Jun 7, 2017 · 2 comments
Closed

AgnosticSNP quality is a string and should be float #26

courcelm opened this issue Jun 7, 2017 · 2 comments

Comments

@courcelm
Copy link
Contributor

courcelm commented Jun 7, 2017

AgnosticSNP quality is a string and should be float

This is an issue for comparison because in python 2.7:

'0.001' > 20
True

For SNP filter this will silently fail:

    def filter(self, chromosome, **kwargs):

        for snp_set, snp in kwargs.iteritems():

                if snp.quality > self.threshold:

                    return SequenceSNP(snp.alt)

snp.quality must be cast to float to obtain the expected result

@tariqdaouda
Copy link
Owner

tariqdaouda commented Jun 8, 2017

True. Where is this snippet coming from?

@courcelm
Copy link
Contributor Author

courcelm commented Jan 8, 2018

Fixed in 1.3.1

@courcelm courcelm closed this as completed Jan 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants