Description Usage Arguments Details Value Examples
View source: R/utility_functions.R
This utility function calcuates the probability of a specific outcome for a full set of values for the explanatory variables in the fitted model.
1  P.X(X, outcome, variable, value)

X 
A real number. This is the number that is picking out one member of the family of probability functions that are consistent with the fitted logisitic model. 
outcome 
An integer specifying a particular outcome. This is one of the values of the outcome variable (i.e. the dependent variable from the model) 
variable 
A column name from the original data frame. This will be the variable one of whose values you are calculating the probability for. 
value 
A specific value of the variable under consideration. This value
must be one of the values actually used in the data frame for

This function is best thought of as a realvalued function of a single variable X, with the function being specified by variable, value and outcome. For a particular value of an explanatory variable, each value of X will return a probability, and the same value of X will, for a different value of the same variable, return a probability that is consistent with the set of estimated coefficients from the logistic model that has been fitted. (The value of the outcome variable is also taken account of too.)
The calculated probability corresponding to the values you have specified.
1  P.X(1.9,2,"gender","female")

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.