STITCH output

77 views
Skip to first unread message

Erik Hanson

unread,
Nov 25, 2019, 6:48:11 PM11/25/19
to STITCH imputation
Hi Robert,

So far STITCH has been running and working quite well for me! I was just wondering if STITCH also outputs the haplotypes constructed by the model or just the imputed genotypes for each sample. Additionally, does STITCH output the posteriors for the individual samples in our population? I cannot find this in any of the output files. 

Best,
Erik Hanson
UC Santa Cruz

Robbie Davies

unread,
Nov 26, 2019, 8:56:42 AM11/26/19
to Erik Hanson, STITCH imputation
Hi Erik,

Per-sample haplotypes, or the internal "ancestral" haplotypes? The former no, imputation (in the normal "diploid" method) is on the genotypes and haplotypes are not explicitly constructed. The later is a soft no, at least not officially in the VCF, but yes you can find them in RData/EM.all.{regionName}.RData as "eHapsCurrent_tc" which for eHapsCurrent_tc[i, j, s] = P(for start s, ancestral haplotype i at SNP j is an alternate base) (note that default S = 1 means 1 repetition so just one set of ancestral haplotypes, where S = some higher number like 4 means the genotype posteriors are averaged over 4 starts, and eHapsCurrent_tc[, , s] is the ancestral haplotypes for start s) 

which "the posteriors for the individual samples"? The genotype posterior (yes, should be in the VCF), for the hidden state (ancestral haplotype posteriors), then setting "output_haplotype_dosages" to TRUE outputs the combined posterior hidden state probability e.g. with K = 4 for a diploid model you'll have for each sample in the VCF for each SNP a vector of length 4 of sum 2 where each entry is P(Q_{t, 1} = k | O, \lambda) + P(Q_{t, 2} = k | O, \lambda) where Q_{t, j} is the posterior hidden state probability for SNP t for haplotype j for j in {1, 2} (and where O = data = sequencing reads, and where \lambda are the parameters of the model)

Hope that all makes sense, let me know if I can clarify the above or if that's not quite what you were going for.

Thanks and best wishes,
Robbie



--
You received this message because you are subscribed to the Google Groups "STITCH imputation" group.
To unsubscribe from this group and stop receiving emails from it, send an email to stitch-imputat...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/stitch-imputation/a32f7a27-217a-4ff3-bf2c-5a565c72c8a8%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages