comparison test-data/output.DupRate_plot.r @ 51:09846d5169fa draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rseqc commit 37fb1988971807c6a072e1afd98eeea02329ee83
author iuc
date Tue, 14 Mar 2017 10:23:21 -0400
parents 6b33e31bda10
children
comparison
equal deleted inserted replaced
50:f242ee103277 51:09846d5169fa
2 par(mar=c(5,4,4,5),las=0) 2 par(mar=c(5,4,4,5),las=0)
3 seq_occ=c(1) 3 seq_occ=c(1)
4 seq_uniqRead=c(40) 4 seq_uniqRead=c(40)
5 pos_occ=c(1) 5 pos_occ=c(1)
6 pos_uniqRead=c(40) 6 pos_uniqRead=c(40)
7 plot(pos_occ,log10(pos_uniqRead),ylab='Number of Reads (log10)',xlab='Frequency',pch=4,cex=0.8,col='blue',xlim=c(1,500),yaxt='n') 7 plot(pos_occ,log10(pos_uniqRead),ylab='Number of Reads (log10)',xlab='Occurrence of read',pch=4,cex=0.8,col='blue',xlim=c(1,500),yaxt='n')
8 points(seq_occ,log10(seq_uniqRead),pch=20,cex=0.8,col='red') 8 points(seq_occ,log10(seq_uniqRead),pch=20,cex=0.8,col='red')
9 ym=floor(max(log10(pos_uniqRead))) 9 ym=floor(max(log10(pos_uniqRead)))
10 legend(300,ym,legend=c('Sequence-base','Mapping-base'),col=c('blue','red'),pch=c(4,20)) 10 legend(300,ym,legend=c('Sequence-based','Mapping-based'),col=c('blue','red'),pch=c(4,20))
11 axis(side=2,at=0:ym,labels=0:ym) 11 axis(side=2,at=0:ym,labels=0:ym)
12 axis(side=4,at=c(log10(pos_uniqRead[1]),log10(pos_uniqRead[2]),log10(pos_uniqRead[3]),log10(pos_uniqRead[4])), labels=c(round(pos_uniqRead[1]*100/sum(pos_uniqRead)),round(pos_uniqRead[2]*100/sum(pos_uniqRead)),round(pos_uniqRead[3]*100/sum(pos_uniqRead)),round(pos_uniqRead[4]*100/sum(pos_uniqRead)))) 12 axis(side=4,at=c(log10(pos_uniqRead[1]),log10(pos_uniqRead[2]),log10(pos_uniqRead[3]),log10(pos_uniqRead[4])), labels=c(round(pos_uniqRead[1]*100/sum(pos_uniqRead*pos_occ)),round(pos_uniqRead[2]*100/sum(pos_uniqRead*pos_occ)),round(pos_uniqRead[3]*100/sum(pos_uniqRead*pos_occ)),round(pos_uniqRead[4]*100/sum(pos_uniqRead*pos_occ))))
13 mtext(4, text = "Reads %", line = 2) 13 mtext(4, text = "Reads %", line = 2)
14 dev.off() 14 dev.off()