Re: [R] Plotting the probability curve from a logit model with 10 predictors

2012-07-09 Thread Frank Harrell
Also: require(rms); ?plot.Predict Frank Greg Snow wrote > > Try the following: > > library(TeachingDemos) > ?TkPredict > fit.glm1 <- glm( Species=='virginica' ~ Sepal.Width+Sepal.Length, > data=iris, family=binomial) >TkPredict(fit.glm1) > > (you may need to instal

Re: [R] Plotting the probability curve from a logit model with 10 predictors

2012-07-07 Thread Greg Snow
Try the following: library(TeachingDemos) ?TkPredict fit.glm1 <- glm( Species=='virginica' ~ Sepal.Width+Sepal.Length, data=iris, family=binomial) TkPredict(fit.glm1) (you may need to install the TeachingDemos package first if you don't already have it installed) You

Re: [R] Plotting the probability curve from a logit model with 10 predictors

2012-07-07 Thread David Winsemius
On Jul 6, 2012, at 4:30 PM, Abraham Mathew wrote: Ok, so let's say I have a logit equation outlined as Y= 2.5 + 3X1 + 2.3X2 + 4X3 + 3.6X4 + 2.2X5 So a one unit increase in X2 is associated with a 2.3 increase in Y, Assuming, that is, you also understand what Y is. From you comments so fa

Re: [R] Plotting the probability curve from a logit model with 10 predictors

2012-07-06 Thread Abraham Mathew
Ok, so let's say I have a logit equation outlined as Y= 2.5 + 3X1 + 2.3X2 + 4X3 + 3.6X4 + 2.2X5 So a one unit increase in X2 is associated with a 2.3 increase in Y, regardless of what the other predictor values are. So I guess instead of trying to plot of curve with all the predictors accounted fo

Re: [R] Plotting the probability curve from a logit model with 10 predictors

2012-07-06 Thread Greg Snow
Look at the Predict.Plot and TkPredict functions in the TeachingDemos package. These will not plot all 11 dimensions at once, but will plot 2 of the dimensions conditioned on the others. You can then change the conditioning to see relationships. These use base rather than ggplot graphics. On Th

Re: [R] Plotting the probability curve from a logit model with 10 predictors

2012-07-05 Thread Bert Gunter
You have an about 11-D response surface, not a curve! -- Bert On Thu, Jul 5, 2012 at 2:39 PM, Abraham Mathew wrote: > I have a logit model with about 10 predictors and I am trying to plot the > probability curve for the model. > > Y=1 = 1 / 1+e^-z where z=B0 + B1X1 + ... + BnXi > > If the mod

[R] Plotting the probability curve from a logit model with 10 predictors

2012-07-05 Thread Abraham Mathew
I have a logit model with about 10 predictors and I am trying to plot the probability curve for the model. Y=1 = 1 / 1+e^-z where z=B0 + B1X1 + ... + BnXi If the model had only one predictor, I know to do something like below. mod1 = glm(factor(won) ~ as.numeric(bid), data=mydat, family=binomi