Produces a more throurough tearsheet with detailed metrics and information
git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@5882 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
parent
1e2892a35d
commit
8a57c52005
|
|
@ -0,0 +1,34 @@
|
||||||
|
source("/humgen/gsa-pipeline/.repository/R/DataProcessingReport/Tearsheet.R")
|
||||||
|
cmdargs = gsa.getargs(
|
||||||
|
list(
|
||||||
|
title = list(value=NA, doc="Title for the tearsheet"),
|
||||||
|
tsv = list(value=NA, doc="pipeline tsv file"),
|
||||||
|
evalroot = list(value=NA, doc="VariantEval file base (everything before the .eval)"),
|
||||||
|
tearout = list(value=NA, doc="Output path for tearsheet PDF")#,
|
||||||
|
),
|
||||||
|
doc="Creates a tearsheet"
|
||||||
|
);
|
||||||
|
|
||||||
|
read.delim(cmdargs$tsv, header=FALSE)->settable
|
||||||
|
|
||||||
|
squids<-unique(settable[,1])
|
||||||
|
|
||||||
|
lane<-data.frame()
|
||||||
|
samp<-data.frame()
|
||||||
|
for(squid in squids){
|
||||||
|
gsa.read.squidmetrics(squid, TRUE)->lanemetrics
|
||||||
|
addlanes<-lanemetrics[which(lanemetrics$"External ID" %in% settable[,2]),]
|
||||||
|
gsa.read.squidmetrics(squid, FALSE)->samplemetrics
|
||||||
|
addsamps<-samplemetrics[which(samplemetrics$"Sample" %in% settable[,2]),]
|
||||||
|
lane<-rbind(lane, addlanes)
|
||||||
|
samp<-rbind(samp, addsamps)
|
||||||
|
}
|
||||||
|
print("Picard Data Obtained...")
|
||||||
|
gsa.read.gatkreport(paste(cmdargs$evalroot, ".eval", sep=""))->basiceval
|
||||||
|
gsa.read.gatkreport(paste(cmdargs$evalroot, ".extraFC.eval", sep=""))->FCeval
|
||||||
|
gsa.read.gatkreport(paste(cmdargs$evalroot, ".extraSA.eval", sep=""))->SAeval
|
||||||
|
print("Evals read")
|
||||||
|
pdf(file= cmdargs$tearout, width=22, height=17, pagecentre=TRUE, pointsize=24)
|
||||||
|
print("PDF created...")
|
||||||
|
tearsheet()
|
||||||
|
dev.off()
|
||||||
Loading…
Reference in New Issue