Skip to content

Commit

Permalink
Changed Glimpse2Imputation QC metrics output format
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelgatzen committed Sep 17, 2024
1 parent 5599798 commit 67dbba2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion GlimpseImputationPipeline/Glimpse2Imputation.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,9 @@ import pandas as pd
hl.init(default_reference='GRCh38', idempotent=True)
vcf = hl.import_vcf('~{imputed_vcf}', force_bgz=True)
qc = hl.sample_qc(vcf)
qc.cols().flatten().rename({'sample_qc.' + col: col for col in list(qc['sample_qc'])}).export('~{output_basename}.qc_metrics.tsv')
qc_pd = qc.cols().flatten().rename({'sample_qc.' + col: col for col in list(qc['sample_qc'])}).to_pandas()
qc_pd = qc_pd.rename(columns={'s': 'sample_id'})
qc_pd.to_csv('~{output_basename}.qc_metrics.tsv', sep='\t', index=False, float_format='%.4f')
EOF
python3 script.py
>>>
Expand Down

0 comments on commit 67dbba2

Please sign in to comment.