[R] question regarding basic stat question

Bryan Hanson hanson at depauw.edu
Tue Feb 22 14:32:14 CET 2011


Daniel, how is the data stored?  The answer to your question may be as  
simple as

 > df <- read.csv("filename.csv")
 > summary(df)

See ?read.csv for info on reading various file formats.

HTH, Bryan
****************
Prof. Bryan Hanson
Dept of Chemistry & Biochemistry
DePauw University
602 S. College Ave
Greencastle IN 46135 USA

On Feb 22, 2011, at 7:20 AM, Daniel Harris wrote:

> Hello
>
> Is it possible to get summary statistics (inc mean, sd etc) from a
> text file that has the following info stored in it?
>
> Height             Frequency
>
> 123                  5
> 124                  8
> 125                  3
> 126                  9
> 127                  7
>
> etc                   etc
>
> Now I know I can convert the file to a single list outside of R using
> python etc and I can convert the file to a single list inside R using
> a series of (what I find) complicated commands.
>
> Is there a simple way of doing summary(Height,Frequency)
>
> Thanks in advance
> Dan
>
> ______________________________________________
> R-help at 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.



More information about the R-help mailing list