Skip to content
Prev 259331 / 398502 Next

Summarising by group

I wonder if someone with more experience than me on using R to summarise
by group wants to post a reply to this 

http://www.analyticbridge.com/group/sasandstatisticalprogramming/forum/t
opics/why-still-use-sas-with-a-lot

To save everyone having to follow the link, the text is copied below

"SAS has some nice features, such as the SQL procedure or simple "group
by" features. Try to compute correlations "by group" in R: say you have
2,000 groups, 2 variables e.g. salary and education level, and 2 million
observations - you want to compute correlation between salary and
education within each group.

It is not obvious, your best bet is to use some R package (see sample
code on Analyticbridge to do it), and the solution is painful, you can
not return both correlation and stdev "by group", as the function can
return only one argument, not a vector. So if you want to return not
just two, but say 100 metrics, it becomes a nightmare."



________________________________________________________________________
The Numerical Algorithms Group Ltd is a company registered in England
and Wales with company number 1249803. The registered office is:
Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom.

This e-mail has been scanned for all viruses by Star. Th...{{dropped:4}}

Thread (20 messages)

Alex Olssen maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 6 Peter Dalgaard maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 7 Ravi Varadhan maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 7 Peter Dalgaard maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 7 Alex Olssen maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 8 Peter Dalgaard maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 9 Martyn Byng Summarising by group May 9 Peter Dalgaard Summarising by group May 9 Alex Olssen maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 9 Mike Marchywka maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 9 Alex Olssen maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 9 Peter Dalgaard maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 9 Peter Dalgaard maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 9 Ista Zahn Summarising by group May 9 Alex Olssen maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 9 Berend Hasselman maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 10 Mike Marchywka maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 12 Ravi Varadhan maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 21 Mike Marchywka maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 21 Mike Marchywka maximum likelihood convergence reproducing Anderson Blundell 1982 Econometrica R vs Stata May 22