Is there a tool to draw local ancestry plots per chromosome?
2
2
Entering edit mode
8.4 years ago
bibb77 ▴ 90

Dear biostars:

I'm doing local ancestry estimations for GWAS data using the LAMP-LD software, I just got the results, which are ranges of ancestry across each chromosome per individual. This is small example of the output for a given chromosome:

00:1935    01:1981    02:50531    00:50937

1: Native American ancestry(red)

0: European ancestry (blue)

2: African ancestry (orange)

00 means that both haplotypes comes from European ancestry, 01 half European and half Native American, 02 half European and half African. The numbers after the semicolon are the number of variants on each haplotype.

I was looking in the web but I haven't found any tool (online or script like in R) that can take that input format and draw a plot like this:

plot

I'll appreciate if you can give some advice

Thanks in advance!

ideogram ancestry lamp-ld • 4.7k views
ADD COMMENT
0
Entering edit mode

Hello,

I was wondering if you were able to successfully find what you were looking for.

Michael

ADD REPLY
0
Entering edit mode

Hello Michael,

I have the same question as above and have not found any R plots or graphing software for LAMP-LD results. Do you have any recommendations?

Thank you.

ADD REPLY
0
Entering edit mode

Hello, Did you ever find a R script or another visualization tool which would enable you to graph your LAMP-LD output? I have the same output format which I would like to graph. Thank you.

ADD REPLY
4
Entering edit mode
4.8 years ago
cruzpedro ▴ 100

Hi, although the topic is old, it might help people coming here to answer this very question.

First use convertLAMPLDout.pl script that comes with LAMPLD to unwind haplotypes perl convertLAMPLDout.pl test_data/lampld.out test_data/lampld.out.long

Then use this script (see lait in http://www.pitt.edu/~wec47/lait.html) to get a more standard file from the above output

perl standardizeOutput.pl lamp-ld 3 lampld.out.long lampld.std_ancestry.txt

Plot in R like this (for ancestries as lines, you can change to rectangles, see https://bernatgel.github.io/karyoploter_tutorial/)*

library(karyoploteR) 

lamp <- read.table("lampld.std_ancestry.txt",  header=F)

lamp.m <- colMeans(lamp[, 2:ncol(lamp)])

tmp <- data.frame(X=lamp.m, ind=rep(1:3))
lamp.df <- unstack(tmp, X~ind)


# Plot
kp <- plotKaryotype(chromosomes="chr11", plot.type=2)

#data.panel=1
kpDataBackground(kp)

#Default axis ====> uncomment for both sides axis 
# kpAxis(kp) 

#Axis on the right side of the data.panel
kpAxis(kp, side = 2) 

snp <- read.table("chr.pos", header = F)

kpPoints(kp, chr="chr11", x=snp$V1, y=lamp.df$X1, pch=".", cex=0.75)
kpPoints(kp, chr="chr11", x=snp$V1, y=lamp.df$X2, pch=".", cex=0.75,col="blue")
kpPoints(kp, chr="chr11", x=snp$V1, y=lamp.df$X3, pch=".", cex=0.75, col="red")

  [1]: http://www.pitt.edu/~wec47/Files/LAIT/standardizeOutput.pl

*Where chr.pos is the posfile you've used as input on your LAMPLD run.

Good luck

ADD COMMENT
0
Entering edit mode

Hi

Does anyone perhaps have a copy of standardizeOutput.pl or of the other LAIT utils?

The GitHub repo only has lait.pl.

The author Daniel Hui has not been able to provide me with the tools.

The site http://www.pitt.edu/~wec47/lait.html no longer exists.

Thanks and best regards!

Fourie

ADD REPLY
4
Entering edit mode
2.9 years ago
4galaxy77 2.8k

MOSAIC does this - as long as your data is phased.

enter image description here

ADD COMMENT

Login before adding your answer.

Traffic: 2867 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6