Predicted Probabilities with Predict.Plot

I'm running the following logistic regression model in R and one of the important predictors is our_bid, which is a numeric and continuous variable that ranges from 0.30 to 0.80. When I attempt to draw the probability curve for the model using the effects package, I was expecting that I could predict the response variable based on our_bid from 0.00 to 2.00. Even though those values aren't present in my data set, I thought I could use the model to predict on values outside the values currently that are in our_bid.

mod1 = glm(factor(won_ping) ~ our_bid +
  age_of_oldest_driver2 + 
  credit_type2 + 
  coverage_type2 +
  home_owner2 +
  state2 +
  currently_insured2 +
  hour_of_day4 +
  data=dat, family=binomial(link="logit"))

Predict.Plot(mod1, pred.var = "our_bid", our_bid = 250, age_of_oldest_driver2 = "22 to 25",      
             credit_type2 = "FAIR", coverage_type2 = "BASIC", home_owner2 = "1",      
             state2 = "top", currently_insured2 = "1", hour_of_day4 = "1pm to 7pm",      
             vehicle_driver_score = "0", plot.args = "list(xlim=c(0,100))", type = "response")

This results in the following plot, which doesn't give all the predicted values from 0 to 1.00. I'm not sure why I'm not able to use the statistical model to predict outside the bounds of the values in that variable (our_bid).


I don't see any need for the rms package above and the Predict.Plot function is not in rms or any of the standard packages.

If you mean the Predict.Plot function from the TeachingDemos package then specifying xlim in the plot.args section only sets the width of the window and does nothing with the predictions. If you read the details section of the help page for Predict.Plot you will see that you need to give it 2 values for the prediction variable if you want to specify the range that it predicts from (otherwise it just uses the range of the data used to fit the model). So it looks like you want our_bid=c(0,100) or something like that. If you provide some data in a reproducible format then we can test and give better advice.

Need Your Help

How do I pass a dynamic URL from XML into an onClick Mouse Event in ActionScript 3?

xml flash actionscript-3 actionscript

I'm loading the XML in, and I'm able to read the XML nodes into text fields in my flash. It is also loading the URL, but the last one from the loop. It's not loading the one that I click on. I tried

Return Struct data type from C-function in Python via SWIG

python c struct swig return-type

I have a C-function which returns a struct data type with several items in it (size_t, char*, int, unsigned and other structs). When I call this function there is no output in python. After some go...

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.