Skip to contents

Mul R2

Usage

Mul_R2(model_input, R)

Arguments

model_input

Model input as a character string. Multiple models need to be on their own line. Model syntax uses lavann like syntax, see details for more details about this syntax.

R

A correlation matrix, most likely this will be the average correlation matrix outputted from the metafor package.

Value

A vector of names

Examples

R <- matrix(c(1, .40, .30,
              .40, 1, .50,
              .30, .50, 1), 3, 3,
            dimnames = list(c("x1", "x2", "y"), c("x1", "x2", "y")))
Mul_R2("y ~ x1 + x2", R)
#>         y 
#> 0.2619048