Learn R Programming

predict3d (version 0.1.5)

restoreData: Restore factors in data.frame as numeric

Description

Restore factors in data.frame as numeric

Usage

restoreData(data)

Arguments

data

A data.frame

Examples

Run this code
fit=lm(mpg~factor(cyl)*factor(am),data=mtcars)
fit=lm(mpg~wt*factor(am),data=mtcars)
fit=lm(mpg~wt*hp,data=mtcars)
restoreData(fit$model)

Run the code above in your browser using DataLab