coldeyes Liao
2008-May-19 19:14 UTC
[R] How to get confidence interval and coefficient in Logic Regression
sorry to bother everyone. i have question to get the coefficient and confidence interval in Logic Regression with Logistic model. below i list the R code X <- matrix(as.numeric(runif(400) < 0.5), 50,8) colnames(X) <- paste("X", 1:ncol(X), sep="") rownames(X) <- paste("case", 1:nrow(X), sep="") # Define expected result: Y = (NOT X1) AND X5 Y <- as.numeric(!X[,1] & X[,5]) z<-as.numeric(runif(50)) model.dat<-cbind(X,z,Y) set.seed(12345) Annealing <- logreg.anneal.control(start = 4, end = -4, iter = 1000, update = 50) logicfit <- logreg(resp=model.dat[,10], bin=model.dat[,1:8],sep=model.dat[,9], type = 3, select = 2, ntrees=2, nleaves=3, anneal.control=Annealing) use names(logicfit) , i didn't see coef class. how to i get the coefficient of the model , especially for the additive effect. is there command i can calculate the sd so that i can have confidence interval. model.dat2<-model.dat secondly i try to use alltrees <- eval.logreg(logicfit , model.dat2) to score a new data set model.dat2. but this doesn't work. thanks for your help. leo [[alternative HTML version deleted]]