Here I have a dataset with 800 positive samples and 800 negative ones
looking like this
y x1 x2
1 0 1
-1 1 1
I want to build a logistic regression model with y as the dependent variable, x1 and x2 as the independent variables (logit(y)=b0+ b1*x1 +b2*x2.). Then I want to compare this model with the NULL model which is b1=0 and b2=0 using a score test. With the P value I get from score test, I can then tell whether the two independent variables are significant related with y.
Here I have a dataset with 800 positive samples and 800 negative ones looking like this
y x1 x2
Does anyone know how to do that in R? Which function should I use? Many many thanks,
[[alternative HTML version deleted]]
Archive maintained by Robert King, hosted by
the discipline of
statistics at the
University of Newcastle,
Archive generated by hypermail 2.2.0, at Fri 04 Jul 2008 - 23:31:41 GMT.
Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.
list of date sections of archive