GenVisR to generate waterfall plot with clinical data: Waterfall plot is not annotating the clinical data
0
0
Entering edit mode
5 months ago
tanbiswas6 ▴ 10

Hi

I want to use GenVisR to generate oncoplot with clinical data. Though I am able to generate waterfall plot but I am not able to generate the plot using clinical data. Below is my code:

myVars <- fread("batch3_with_VAF.txt")
myVars <- myVars[,.(`Tumor_Sample_Barcode`, `Hugo_Symbol`, `Variant_Classification`, `HGVSp_Short`)]
setnames(myVars, c("sample", "gene", "mutation", "amino acid change"))

myHierarchy <- data.table("mutation"=c("Nonsense_Mutation", "Frame_Shift_Del", "Frame_Shift_Ins", "In_Frame_Del", "splice_site_del", "Splice_Site", "Missense_Mutation", "splice_region", "rna"), color=c("#FF0000", "#00A08A", "#F2AD00", "#F98400", "#5BBCD6", "#046C9A", "#D69C4E", "#000000", "#446455"))

plotData <- Waterfall(myVars, mutationHierarchy = myHierarchy)

pdf(file="Figure_try.pdf", height=8, width=12)
drawPlot(plotData)
dev.off()

myClinical <- fread("clinical_data.txt")
myClinical <- myClinical[,.(`Tumor_Sample_Barcode`, `Gleason_Score`, `PSA`)]
setnames(myClinical, c("sample", "Gleason_Score", "PSA"))
myClinical[,sample := gsub("IITK-P+","",sample)]

head(myClinical)
sample Gleason_Score                    PSA

   <char>        <char>                 <char>
1:  01-TD           GS9      more_than_hundred
2:  02-TD           GS8      more_than_hundred
3:  03-TD           GS8 more_than_five_hundred
4:  04-TD           GS7 more_than_five_hundred


myClinicalColors <- c("GS6"="#798E87", "GS7"="#C27D38", "GS8"="#CCC591", "GS9"="#76ABE2", "GS10"="#29211F", "more_than_fifteen"="#A6FF80", "more_than_hundred"="#9C964A", "more_than_five_hundred"="#85D4E3")

clinicalData <- Clinical(inputData = myClinical, palette = myClinicalColors, legendColumns = 2)
plotData <- Waterfall(myVars, mutationHierarchy = myHierarchy, clinical = clinicalData)

pdf(file="Figure_2_my.pdf", height=8, width=12)
drawPlot(plotData)
dev.off()

I am getting the same waterfall plot with no annotation of clinical data. Please let me know hoe to solve this.

Regards,
Tanay

Mutation GenVisR waterfall-plot oncoplot r • 259 views
ADD COMMENT

Login before adding your answer.

Traffic: 1748 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