SOmething like this should work where you 'split' you data frame by
the contents of the first column and then plot the data:

Dens <- split(D, D[,1])
for (i in Dens){  # process each species
    jpeg(paste(i[1,1], '.jpg', sep='')  # create file with species name
    plot(....., main=i[1,1])
    dev.off()
}


On Sat, Sep 5, 2009 at 7:52 AM, Антон Морковин<a-morko...@yandex.ru> wrote:
>
> I have a several questions about R graphic properties.
> I use a "barplot2" function for creating plots with error bars. My data 
> include species' names in first column, and I need make plots for each 
> species. I know how to select species for each plot:
>
> D<-read.table("FD_R.txt", h=T)
> Dens<-D[D[,1]=="Sit.eur",]
>
> but I want to make a cycle which will automatically change the species' name 
> and save each plot in "jpg" file. How can I do it?
>
> Also, my data include results of two-year work, and I want to make two plots 
> for each year one above another in the same box. Is it possible?
>
> And the last question: are there any functions in R which will allow to get 
> data from Access? I know about "getfromaccess" function from vegan packcage, 
> but it works only with environmental data with very restricted structure.
>
> I would be very much obliged for your answers.
>
> A. A. Morkovin, PhD student.
>
> --
>
> ______________________________________________
> R-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



-- 
Jim Holtman
Cincinnati, OH
+1 513 646 9390

What is the problem that you are trying to solve?

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to