Re: [R] How to change the class of data?

From: Frankg <>
Date: Wed, 11 Jun 2008 23:58:40 -0700 (PDT)

When you have a data X with a class factor, you can transform it to numeric as


to transform it to a factor again use


View this message in context:
Sent from the R help mailing list archive at

______________________________________________ mailing list
PLEASE do read the posting guide
and provide commented, minimal, self-contained, reproducible code.
Received on Thu 12 Jun 2008 - 07:01:12 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 12 Jun 2008 - 07:30:45 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.

list of date sections of archive