Make Factor or Numeric Variable out of Vector

DESCRIPTION:

Creates a factor or numeric variable out of a vector object.

USAGE:

as.variable(x) 

REQUIRED ARGUMENTS:

x
a vector, typically a column of a numeric or character matrix, in the way as.variable() is used by as.data.frame() and data.frame().

VALUE:

If the data are numbers (whether the mode is numeric or character), a numeric vector. Otherwise a factor.