Form predictions using the estimated model parameters from stochastic gradient descent.
# S3 method for sgd
predict(object, newdata, type = "link", ...)predict_all(object, newdata, ...)
object of class sgd
.
design matrix to form predictions on
the type of prediction required. The default "link" is on the scale of the linear predictors; the alternative '"response"' is on the scale of the response variable. Thus for a default binomial model the default predictions are of log-odds (probabilities on logit scale) and 'type = "response"' gives the predicted probabilities. The '"terms"' option returns a matrix giving the fitted values of each term in the model formula on the linear predictor scale.
further arguments passed to or from other methods.
A column of 1's must be included to newdata
if the
parameters include a bias (intercept) term.