openvax / pyensembl

Python interface to access reference genome features (such as genes, transcripts, and exons) from Ensembl
Apache License 2.0
365 stars 66 forks source link

Convert TSL to int? #214

Closed iskandr closed 5 years ago

iskandr commented 5 years ago

Hey @vladsaveliev -- since you changed "NA" to None for transcript support levels, do you think we should have the value always be int or `None?

Also, to help me remember, pasting the meanings of the TSL values here (copied from https://useast.ensembl.org/info/genome/genebuild/transcript_quality_tags.html#tsl):

tsl1 – all splice junctions of the transcript are supported by at least one non-suspect mRNA tsl2 – the best supporting mRNA is flagged as suspect or the support is from multiple ESTs tsl3 – the only support is from a single EST tsl4 – the best supporting EST is flagged as suspect tsl5 – no single transcript supports the model structure tslNA – the transcript was not analysed for one of the following reasons: pseudogene annotation, including transcribed pseudogenes human leukocyte antigen (HLA) transcript immunoglobin gene transcript T-cell receptor transcript single-exon transcript (will be included in a future version)

vladsavelyev commented 5 years ago

Hi,

I actually changed it to always be int or None, after your questions in the original issue :) I think my answers to your review disappeared after I rebased. But anyway, that's happening in the merged version: https://github.com/vladsaveliev/pyensembl/blob/74f55edae45271ade516a29fc09aeb9aa2186b92/pyensembl/genome.py#L879-L883 We either make it int, or set None otherwise.

iskandr commented 5 years ago

👍