Skip to content
Prev 268592 / 398502 Next

Renaming levels of a factor in a dataframe

Tyler,

 

Tried your solution: levels (Data1$Site <- list(Fw = c("AB"), Est = c("DE"))) 

 

but still got a NULL response to str(Data1) and an alternating list of Fw, Est, Fw, Est under Site when looked at in the Data editor in R console. The use of the "levels" function would seem to be appropriate but tricky to use.  Any other ideas would be welcome.

 

Regards,

BJ

________________________________