Skip to content
Prev 188598 / 398500 Next

truncating values into separate categories

I must apoligize, as i want clear of what i wanted to occur.  i dont want to
count the occurences but rather recode them.  I am trying to replace all of
the values with the new coded values in Person_CAT.  SO NP <- c(1,  1,  2, 
1, 1,  2,  2,  1,  4,  1,  0,  5,  
+ 3,  3,  1,  5,  3, 5, 1, 6, 1, 2, 2, 2,
+ 4, 4, 1, 2, 1, 3, 3, 1,  2,  2,  1,  2, 1, 2,
+ 2, 3, 1, 1, 4, 4, 1, 1, 1, 2, 2, 2)




and Person_CAT: 1, 1, 2, 1, 1, 2, 2, 1, 4, 1, NA, 4..... and so on.  This
task would easily be done in SPSS but i am trying to automate it using R.  I
hope this is more clear,
Bill.Venables wrote: