I have a question in R. In directory H:/Delta_angle I have 19 files like this: ALA.delta ASN.delta ASP.delta CYS.delta GLN.delta GLU.delta HIS.delta ILE.delta LEU.delta LYS.delta MET.delta PHE.delta PRO.delta SER.delta THR.delta TRP.delta TYR.delta VAL.delta I want to read these files to 19 data sets in R. All these data sets have "P","AA",index","delta" columns I want to do histogram for variable "delta" in each data set, and label the histogram by mean, standard deviation and number of observation for "delta" column. Do you know how to do these in R? thanks Aimin Yan [[alternative HTML version deleted]]
This question (paraphrase: How do I process a lot of homologous files?) or something similar has been asked (and answered) a lot lately. For example, look at this thread from today's posting to r-help: http://news.gmane.org/find-root.php?group=gmane.comp.lang.r.general&article=72254 Chuck p.s. If you have not read the posting guide (see below), do. On Tue, 24 Oct 2006, Aimin Yan wrote:> I have a question in R. > > In directory H:/Delta_angle > I have 19 files like this: > ALA.delta > ASN.delta > ASP.delta > CYS.delta > GLN.delta > GLU.delta > HIS.delta > ILE.delta > LEU.delta > LYS.delta > MET.delta > PHE.delta > PRO.delta > SER.delta > THR.delta > TRP.delta > TYR.delta > VAL.delta > > I want to read these files to 19 data sets in R. > All these data sets have "P","AA",index","delta" columns > I want to do histogram for variable "delta" in each data set, > and label the histogram by mean, standard deviation and number of > observation for > "delta" column. > Do you know how to do these in R? > > > thanks > > Aimin Yan > > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at stat.math.ethz.ch 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. >Charles C. Berry (858) 534-2098 Dept of Family/Preventive Medicine E mailto:cberry at tajo.ucsd.edu UC San Diego http://biostat.ucsd.edu/~cberry/ La Jolla, San Diego 92093-0717
Hi On 24 Oct 2006 at 10:03, Aimin Yan wrote: Date sent: Tue, 24 Oct 2006 10:03:08 -0500 To: r-help at stat.math.ethz.ch From: Aimin Yan <aiminy at iastate.edu> Subject: [R] for help> I have a question in R. > > In directory H:/Delta_angle > I have 19 files like this: > ALA.delta > ASN.delta > ASP.delta > CYS.delta > GLN.delta > GLU.delta > HIS.delta > ILE.delta > LEU.delta > LYS.delta > MET.delta > PHE.delta > PRO.delta > SER.delta > THR.delta > TRP.delta > TYR.delta > VAL.delta > > I want to read these files to 19 data sets in R. > All these data sets have "P","AA",index","delta" columns > I want to do histogram for variable "delta" in each data set, > and label the histogram by mean, standard deviation and number of > observation for "delta" column. Do you know how to do these in R?I hope I would manage with some effort. Believe me, you could manage too with similar effort. Look at read.table, hist, mean, sd, length help page Read some intro manual provided with installation, especially R-data and R-intro Maybe you can look into help archives. At least I do it if I meet some problem. And before your next post you shall just look into posting guide. HTH Petr> > thanks > > Aimin Yan > > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at stat.math.ethz.ch 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.Petr Pikal petr.pikal at precheza.cz