Either of these will do it:
head(temp, Inf)
class(temp) <- "matrix"
On Wed, Jun 4, 2008 at 3:20 PM, <[EMAIL PROTECTED]> wrote:
>
> can someone show me how to convert a table to a data.frame or a matrix ? I
> tried below and as.data.frame rearranges the columns
> similarly to a melt from reshape
Hi Mark,
Try this:
as.data.frame.matrix(temp)
or
as.data.frame(unclass(temp))
On Wed, Jun 4, 2008 at 4:20 PM, <[EMAIL PROTECTED]> wrote:
>
> can someone show me how to convert a table to a data.frame or a matrix ? I
> tried below and as.data.frame rearranges the columns
> similarly to a melt
can someone show me how to convert a table to a data.frame or a matrix ?
I tried below and as.data.frame rearranges the columns
similarly to a melt from reshape and as.matrix didn't change it. I
actually would prefer to change it to a dataframe but if someone
can show me how to convert it to a
3 matches
Mail list logo