Skip to content

table: output: all variables in rows

3 messages · David Winsemius, Marion Wenty

#
On Apr 2, 2012, at 7:11 AM, Marion Wenty wrote:

            
You can use the order() function with "[" to rearrange this to suit  
you needs:

 > as.data.frame(xtabs(~age+county, data=D))
   age county Freq
1   8      B    1
2   9      B    0
3  10      B    0
4   8      W    0
5   9      W    1
6  10      W    1
Posting in HTML is considered impolite on Rhelp.
2 days later