Displaying 1 result from an estimated 1 matches for "tp1840718p1840730".
Did you mean:
tp1840718p1840718
2010 Apr 15
2
Summarization
Hi All
I have a vector x containing 2 levels
x = c(1,1,1,0,0,0,0,1,1,0,0,0,1,1,0)
I would like to derive the following summarization
Level Count
1 3
0 4
1 2
0 3
1 2
0 1
I have generated an inelegant solution using lags and loops but feel sure
that there must be a better approach. If anyone has any thoughts I would be
very grateful if you would share them.
Thanks and best regards
Pete
--