Regression

Share:

Description

Regression

Usage

1
rmatReg(r_mat, y_col, x_col)

Arguments

r_mat

A correlation matrix.

y_col

The column representing the criterion variable.

x_col

A vector of columns representing predictor variables.

Value

Regression beta weights and R2.

Author(s)

Allen Goebl and Jeff Jones

Examples

1
2
3
4
5
6
7
8
9
Rs <- matrix(c(1.0, 0.2,  0.3, 0.4, -0.4,
              0.2, 1.0,  0.5, 0.1,  0.1,
              0.3, 0.5,  1.0, 0.2, -0.3,
              0.4, 0.1,  0.2, 1.0,  0.4,
             -0.4, 0.1, -0.3, 0.4,  1.0), 5, 5)
ys <- 5
xs <- 1:4

rmatReg(Rs, ys, xs)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.