User Tools

Site Tools


allelic_size_range

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
allelic_size_range [2007/12/21 12:07] – created heidiallelic_size_range [2008/09/23 14:54] (current) heidi
Line 1: Line 1:
 ====== Allelic size range ====== ====== Allelic size range ======
 +===== barplot =====
   * file: bar_AllelicSizeRang.r   * file: bar_AllelicSizeRang.r
   * documentation page: 3   * documentation page: 3
Line 22: Line 23:
          ylim=c(0,(max(Data3)+(max(Data3)/4))))          ylim=c(0,(max(Data3)+(max(Data3)/4))))
 </code> </code>
 +
 +===== lines =====
 +  * file: lines_AllelicSizeRang.r
 +  * document page: 10
 +
 +\\
 +**code:**
 +<code>
 +read.table("D:/Master/R_Daten/AllelicSizeRange/AllelicSizeRange_mic.txt", skip=4 ,row.names=1, fill=TRUE )-> Data
 +
 +a <- nrow(Data)
 +b <- ncol(Data)
 +
 +Data <- as.matrix.data.frame(Data)
 +
 +Data <- Data[1:(a-2),1:(b-3)]
 +nRow <- nrow(Data)
 +nCol <- ncol(Data)
 +
 +x <- 1
 +               
 +plot(Data[x,], type="l", xlab="Population", ylab="Allelic size", main="Allelic size range at different loci",
 +     ylim=c(0,(max(Data)+(max(Data)/4))), xaxt="n", col=1, lwd=1.5 )
 +    
 +    x <- x + 1
 +    while(x <= nRow){
 +        lines(Data[x,], col=x, lwd=1.5)
 +        x <- x + 1
 +    }
 +    axis(1, 1:nCol)
 +    legend("topright", legend=c(1:(x-1)), lty=1, bty="n", col=c(1:x), lwd=1.5, title="Locus")
 +</code>
 +
 +
  
  
allelic_size_range.1198235268.txt.gz · Last modified: 2008/07/22 13:29 (external edit)