Gets the conditional (or marginal) R2 value for the 'response' for an mb_analysis object.

# S3 method for class 'mb_analysis'
R2(
  object,
  response,
  marginal = FALSE,
  term = "prediction",
  parallel = getOption("mb.parallel", FALSE),
  quiet = getOption("mb.quiet", TRUE),
  beep = getOption("mb.beep", FALSE),
  ...
)

Arguments

object

The object.

response

A string specifying the column in the data corresponding to the response.

marginal

A flag indicating whether to calculate the marginal or conditional R2 value.

term

A string of the term in new_expr.

parallel

A flag indicating whether to do predictions using parallel backend provided by foreach.

quiet

A flag indicating whether to disable tracing information.

beep

A flag indicating whether to beep on completion of the analysis.

...

Unused

Value

A number of the R2 value.

Details

The conditional R2 value is the proportion of the variance in the response predicted by the full model. The marginal R2 values is just for the fixed effects ie after marginalizing out the random effects.