Skip to content

Commit

Permalink
Fix tests...
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremyWesthead committed Mar 22, 2023
1 parent 40244d6 commit 15e5012
Showing 1 changed file with 20 additions and 19 deletions.
39 changes: 20 additions & 19 deletions gnomonicus/gnomonicus.py
Original file line number Diff line number Diff line change
Expand Up @@ -304,25 +304,26 @@ def populateMutations(
mutations = pd.concat([mutations, geneMutations])
else:
mutations = geneMutations
#Ensure correct datatypes
mutations = mutations.astype({'MUTATION': 'str',
'GENE': 'str',
'NUCLEOTIDE_NUMBER': 'float',
'NUCLEOTIDE_INDEX': 'float',
'GENE_POSITION': 'float',
'ALT': 'str',
'REF': 'str',
'CODES_PROTEIN': 'bool',
'INDEL_LENGTH': 'float',
'INDEL_NUCLEOTIDES': 'str',
'IS_CDS': 'bool',
'IS_HET': 'bool',
'IS_NULL': 'bool',
'IS_PROMOTER': 'bool',
'IS_SNP': 'bool',
'AMINO_ACID_NUMBER': 'float',
'AMINO_ACID_SEQUENCE': 'str'
})
if mutations is not None:
#Ensure correct datatypes
mutations = mutations.astype({'MUTATION': 'str',
'GENE': 'str',
'NUCLEOTIDE_NUMBER': 'float',
'NUCLEOTIDE_INDEX': 'float',
'GENE_POSITION': 'float',
'ALT': 'str',
'REF': 'str',
'CODES_PROTEIN': 'bool',
'INDEL_LENGTH': 'float',
'INDEL_NUCLEOTIDES': 'str',
'IS_CDS': 'bool',
'IS_HET': 'bool',
'IS_NULL': 'bool',
'IS_PROMOTER': 'bool',
'IS_SNP': 'bool',
'AMINO_ACID_NUMBER': 'float',
'AMINO_ACID_SEQUENCE': 'str'
})
#Add minor mutations (these are stored separately)
if reference.minor_populations or sample.minor_populations:
#Only do this if they exist
Expand Down

0 comments on commit 15e5012

Please sign in to comment.