typecast {mi}R Documentation

Variables type

Description

Function for determinig the variable type.

Usage

  typecast( object )
  ## S4 method for signature 'ANY':
  typecast( object )
  ## S4 method for signature 'matrix':
  typecast( object )
  ## S4 method for signature 'data.frame':
  typecast( object )  
  ## S4 method for signature 'list':
  typecast( object )

Arguments

object Vector, matrix, or data frame of data to determin the type of.

Details

The variable type of a vector, or vector of variable types for each variable in the dataset.

Value

fixed varaibles that contain only one value.
binary variables that contain two values.
ordered-categorical variables that contain 3 to 5 postive values.
unorderd-categorial variables that contain characters or more than 5 postive levels
positive-continuous variables that contain more than 5 postive values, NOT including 0s.
nonnegative variables that contain more than 5 postive values, including 0s.
continuous variables that are not belong to any of the above types.
log-continuous log-scaled continuous variable

Author(s)

Yu-Sung Su ys463@columbia.edu, Masanao Yajima yajima@stat.columbia.edu, M.Grazia Pittau grazia@stat.columbia.edu

References

Yu-Sung Su, Andrew Gelman, Jennifer Hill, Masanao Yajima. Forthcoming. “Multiple Imputation with Diagnostics (mi) in R: Opening Windows into the Black Box”. Journal of Statistical Software.

See Also

mi

Examples

data(CHAIN)
class(CHAIN)

typecast(CHAIN[,1]) # for vector

typecast(as.matrix(CHAIN))# for matrix

typecast(CHAIN) # for data.frame

[Package mi version 0.08-06 Index]