deeenes

Untitled

Apr 3rd, 2013
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
R 0.55 KB | None | 0 0
  1. require(vegan)
  2. require(BiodiversityR)
  3.  
  4. com<-read.csv("com_aveOR.csv", sep=";", dec=",", header=T)
  5. nevek<-read.csv("sepOR.csv", sep=";", dec=",", header=T)
  6.  
  7.  
  8. years <- seq(1988,2012)
  9.  
  10. i <- j <- 1
  11. c <- rainbow(dim(com[rowSums(com)>0,]))
  12. s <- FALSE
  13. yy <- years[rowSums(com)>0]
  14.  
  15. for(yr in years){
  16.     if(sum(com[i,])>0){
  17.         r <- renyiresult(com,y=nevek,factor='Year',method='s',level=paste("y",yr,sep=""))
  18.         renyiplot(r,addit=s,legend=FALSE,col=c[j],ylim=c(0,3))
  19.         j <- j+1
  20.     }
  21.     s <- TRUE
  22.     i <- i+1
  23. }
  24.  
  25. legend(x=1,y=2.2,legend=yy,col=c,lty=1,pch=1)
Advertisement
Add Comment
Please, Sign In to add comment