Displaying 1 result from an estimated 1 matches for "mydata12".
Did you mean:
mydata1
2011 Oct 19
1
Subsetting data by eliminating redundant variables
...,'c'),n,replace=TRUE))
x6 <- 1*(x5=='a' | x5=='c')
data1 <- cbind(x1,x2,x3,x4,x5,x6)
data2 <- data.frame(data1)
outredun <- redun(~., data=data2, r2=.8,)
outredun
#outredun1 <- capture.output(redun(~., data=data2, r2=.8,))
#outredun1
#x25 <- outredun1[25]
#mydata12 <- daat1[myvars] #myvars I need to pass to retain variables
which gives me , say for this example Rendundant variables:x6 x4 x3 and
Predicted from variables: x1 x2 x5 as output in console.
I want to subset my original data with either by keeping 'Predicted from
variables' or by dropi...