Re: [R] Changing an unordered factor into an ordered factor

2010-02-04 Thread Mathew, Abraham T
0 0 3. This worked fine in my made up scenario, but not when I played with the real data. 4.This is a large data set, by my standards at least, but I've included it. Thanks for all the helpI'll continue to play with it. From: Davi

Re: [R] Changing an unordered factor into an ordered factor

2010-02-04 Thread David Winsemius
xo) xo xoppose havent thought favor favor 0 0 2 havent thought 0 1 0 oppose 2 0 0 3. This worked fine in my made up scenario, but not when I played with the real data. "Pl

Re: [R] Changing an unordered factor into an ordered factor

2010-02-04 Thread David Winsemius
On Feb 4, 2010, at 5:58 AM, Oliver Gondring wrote: Hi Mathew, I'm trying to change an unordered factor into an ordered factor: Help it's all about reordering the factor levels, right? It's hard to tell. You could be correct, but the OP never described his reasons for wanting "ordered"

Re: [R] Changing an unordered factor into an ordered factor

2010-02-04 Thread Oliver Gondring
Hi Mathew, I'm trying to change an unordered factor into an ordered factor: Help it's all about reordering the factor levels, right? Have a look at this one: http://rwiki.sciviews.org/doku.php?id=tips:data-factors:factors The third textbox on the page (search for the string: "Reorder facto

[R] Changing an unordered factor into an ordered factor

2010-02-03 Thread Mathew, Abraham T
I'm trying to change an unordered factor into an ordered factor: data96$RV961327 <- data96$V961327 data96$RV961327[data96$V961327 %in% levels(data96$V961327)[4]] <- NA data96$RV961327[data96$V961327 %in% levels(data96$V961327)[5]] <- NA data96$RV961327 <- factor(data96$RV961327) attributes(data