dsldLogit | R Documentation |
Comparison of conditions for sensitive groups via logistic regression models, with or without interactions with the sensitive variable.
dsldLogit(data, yName, sName, sComparisonPts = NULL, interactions = FALSE,
yesYVal)
## S3 method for class 'dsldGLM'
summary(object,...)
## S3 method for class 'dsldGLM'
predict(object,xNew,...)
## S3 method for class 'dsldGLM'
coef(object,...)
## S3 method for class 'dsldGLM'
vcov(object,...)
data |
Data frame used to train the linear model; will be split according to
each level of |
yName |
Name of the response variable column. |
sName |
Name of the sensitive attribute column. |
interactions |
If TRUE, fit interactions with the sensitive variable. |
sComparisonPts |
If |
yesYVal |
Y value to be considered 'yes', to be coded 1 rather than 0. |
object |
An object returned by |
xNew |
Dataframe to predict new cases. Must be in the same format
as |
... |
Further arguments. |
The dsldLogit
function fits a logistic
regression model to the response variable. Interactions are handled
as in dsldLinear
.
The dsldLog
function returns an S3 object of class 'dsldGLM',
with one component for each level of S. Each component includes
information about the fitted model.
N. Matloff, A. Mittal, A. Ashok
data(lsa)
newData <- lsa[c(2,22,222,2222),-c(8,11)]
log1 <- dsldLogit(lsa,'bar','race1', newData, interactions = TRUE, 'TRUE')
coef(log1)
vcov(log1)
summary(log1)
predict(log1, newData)
log2 <- dsldLogit(data = lsa,
yName = 'bar',sName = 'gender',
interactions = FALSE, yesYVal = 'TRUE')
summary(log2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.