Skip to content

Commit

Permalink
Fixed missing gt value. Slight modifications to snplst table.
Browse files Browse the repository at this point in the history
  • Loading branch information
Gavriel Matt authored and xzhou82 committed Nov 7, 2023
1 parent 4d45d1b commit ed56ade
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
12 changes: 5 additions & 7 deletions client/termsetting/handlers/snplst.ts
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ async function makeEditMenu(self: SnpsTermSettingInstance, div0: any) {
validateBtn.text('Validate variants').property('disabled', false)
})

const snplstTableDiv = editUIholder.append('div').style('margin-bottom', '20px')
const snplstTableDiv = editUIholder.append('div').style('margin-bottom', '25px')
const [input_AFcutoff, select_alleleType, select_geneticModel, select_missingGenotype] = makeSnpSelect(
editUIholder.append('div'),
self,
Expand Down Expand Up @@ -291,9 +291,7 @@ function initSnpEditTable(div: any, self: SnpsTermSettingInstance, select_allele
.append('p')
.style('opacity', 0.8)
.style('font-size', '.8em')
.html(
'<sup><b>*</b></sup> Number of samples with at least one valid genotype.<br><sup><b>**</b></sup>Effect alleles are highlighted in red. Click on an allele to set as the effect allele.'
)
.html('Effect alleles are highlighted in red. Click on an allele to set as the effect allele.')
}

function renderSnpEditTable(self: SnpsTermSettingInstance, select_alleleType: any) {
Expand All @@ -302,9 +300,9 @@ function renderSnpEditTable(self: SnpsTermSettingInstance, select_alleleType: an
const title_tr = self.dom.snplst_table.append('tr').style('opacity', 0.4)
const col_titles = [
{ title: 'Variants' },
{ title: 'No. samples<sup><b>*</b></sup>' },
{ title: 'Reference allele<sup><b>**</b></sup><br>(frequency)' },
{ title: 'Alternative allele(s)<sup><b>**</b></sup><br>(frequency)' },
{ title: '# genotyped<br>samples' },
{ title: 'Reference allele<br>(frequency)' },
{ title: 'Alternative allele(s)<br>(frequency)' },
{ title: 'Genotype<br>(frequency)' },
{ title: 'Delete' }
]
Expand Down
2 changes: 1 addition & 1 deletion server/src/termdb.snp.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ validateInputCreateCache_by_coord

const bcfformat_snplst = '%CHROM\t%POS\t%REF\t%ALT[\t%TGT]\n'
const bcfformat_snplocus = '%POS\t%ID\t%REF\t%ALT\t%INFO[\t%TGT]\n'
const missing_gt = '.'
const missing_gt = './.'
const snplocusMaxVariantCount = 1000

export async function validate(q, tdb, ds, genome) {
Expand Down

0 comments on commit ed56ade

Please sign in to comment.