Re: [R] Looking for a comprehensive descriptive statistics package

From: Roland Rau <roland.rproject_at_gmail.com>
Date: Tue, 08 May 2007 14:31:22 -0400

Hi,

summary(yourdata) is often a very good starting point for descriptive data statistics. Or you can write your own little function which returns what you actually like to see (the code below was written very quickly. No care is taken for the presence of missing values or anything else).

exampledata <- rnorm(10000)
summary(exampledata)
desc <- function(mydata) {

   require(e1071)
   quantls <- quantile(x=mydata, probs=seq(from=0, to=1, by=0.25))    themean <- mean(mydata)
   thesd <- sd(mydata)
   kurt <- kurtosis(mydata)
   skew <- skewness(mydata)
   retlist <- list(Quantiles=quantls, Mean=themean, StandDev=thesd,

                   Skewness=skew, Kurtosis=kurt)
   return(retlist)
}

descstats <- desc(exampledata)
descstats

I hope this helps,
Roland

David Kaplan wrote:
> Hi all,
>
> I'm looking for a package that will give me comprehensive set of
> descriptive statistics, including skew and kurtosis. Also, is there a
> similar package that will provide multivariate descriptive statistics as
> well? Thanks in advance,
>
> David
>
>



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. Received on Tue 08 May 2007 - 18:35:57 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 08 May 2007 - 20:33:26 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.