predict.spar {spareg}R Documentation

predict.spar

Description

Predict responses for new predictors from 'spar' object

Usage

## S3 method for class 'spar'
predict(
  object,
  xnew,
  type = c("response", "link"),
  avg_type = c("link", "response"),
  nummod = NULL,
  nu = NULL,
  coef = NULL,
  ...
)

Arguments

object

result of spar function of class 'spar'.

xnew

matrix of new predictor variables; must have same number of columns as x.

type

the type of required predictions; either on response level (default) or on link level

avg_type

type of averaging the marginal models; either on link (default) or on response level

nummod

number of models used to form coefficients; value with minimal validation Meas is used if not provided.

nu

threshold level used to form coefficients; value with minimal validation Meas is used if not provided.

coef

optional; result of coef.spar can be used.

...

further arguments passed to or from other methods

Value

Vector of predictions


[Package spareg version 1.0.0 Index]