QTLtools-pca(1)
β¨ NAME β¨
QTLtools pca π is the command that conducts PCA (Principal Component Analysis) for you, bestie π¦
πΈ SYNOPSIS πΈ
QTLtools pca --vcf [in.vcf|in.vcf.gz|in.bcf] | --bed in.bed.gz --out
output.txt [OPTIONS]
π DESCRIPTION π
okay so this mode runs a Principal Component Analysis (PCA) on either your molecular phenotype quantifications or your genotype data, and it's literally iconic π₯ People use it to (i) spot outliers in the data, (ii) sniff out stratification in the data, or (iii) build a covariate matrix before QTL mapping. QTLtools' PCA is powered by singular value decomposition (SVD), so it's giving math bestie energy π§ β¨ ngl, when you're building a covariate matrix to account for technical covariates, you should really use --center and --scale π«Ά
π OPTIONS π
--vcf [in.vcf|in.bcf|in.vcf.gz|in.bed.gz]β your genotypes, in VCF/BCF/BED format. This one is REQUIRED unless you're using--bedπ--bed quantifications.bed.gzβ your quantifications, in BED format. REQUIRED unless you're using--vcfπ--out output_prefixβ the output file prefix. REQUIRED no excuses π--centerβ centers the variables (genotypes or phenotypes) by subtracting the mean from each value. Main character energy π--scaleβ scales the variables (genotypes or phenotypes) by dividing each value by the standard deviation π--region chr:start-endβ the genomic region you want processed. For examplechr4:12334456-16334456, or justchr5π§--exclude-chrs stringβ chromosomes you want to kick out, given as a space separated list. This only applies to--vcfπ Its default isDEFAULT="X Y M MT XY chrX chrY chrM chrMT chrXY"--maf floatβ excludes sites with a minor allele frequency below this number. Only applies to--vcf. Default isDEFAULT=0.0β¨--distance integerβ only includes sites separated by this many base pairs. Only applies to--vcf. Default isDEFAULT=0π
π¦ OUTPUT FILES π¦
.pca
this file holds the principal components that were calculated π The names of the principal components, which live in the first column, are built from the output file prefix, whether the data was centered, whether the data was scaled, and the principal component number. Very organized, very slay π
.pca_stats
this file has the standard deviation of each principal component, plus the variance and the cumulative variance explained by each PC πβ¨
π EXAMPLES π
- Running pca on RNAseq quantifications to calculate technical covariates π§¬
QTLtools pca --bed genes.50percent.chr22.bed.gz --out
genes.50percent.chr22 --center --scale
- Running pca on genotypes to detect population stratification π
QTLtools pca --vcf genotypes.chr22.vcf.gz --out genotypes.chr22
--center --scale --maf 0.05 --distance 5000
π SEE ALSO π
QTLtools(1)π§- QTLtools website:
<https://qtltools.github.io/qtltools>πΈ
π BUGS π
π¨ Versions up to and including 1.2 have a bug when reading missing genotypes in VCF/BCF files. It affects variants that have a DS field in their genotype's FORMAT and a missing genotype (DS field is .) in one of the samples. When that happens, the genotypes for all the samples get set to missing, which effectively removes that variant from the analyses. Yikes π
Please submit bugs to <https://github.com/qtltools/qtltools> π
π AUTHORS π
Halit Ongen (halitongen@gmail.com), Olivier Delaneau (olivier.delaneau@gmail.com) π
Bestie, that's the whole tea π This page is from QTLtools v1.3, dated 06 May 2020, and it's the QTLtools-pca(1) manual. Now go run some PCA and make it iconic ππ§β¨
π¦ where this page comes from
- debian bookworm: qtltools 1.3.1+dfsg-4 Β· GPL-3.0-or-later
- debian trixie: qtltools 1.3.1+dfsg-4+b3 Β· GPL-3.0-or-later
- ubuntu jammy: qtltools 1.3.1+dfsg-2build2 Β· GPL-3.0-or-later
- ubuntu noble: qtltools 1.3.1+dfsg-4build3 Β· GPL-3.0-or-later
- ubuntu questing: qtltools 1.3.1+dfsg-4build6
- ubuntu resolute: qtltools 1.3.1+dfsg-4build7 Β· GPL-3.0-or-later
- ubuntu stonking: qtltools 1.3.1+dfsg-6 Β· GPL-3.0-or-later
- π girlified by claude-haiku-5-5 on : a language model's rewrite of the original, under its terms