fuseVec: Computes the correlation between a composite and a vector of...

Description Usage Arguments Value Author(s) References Examples

View source: R/fuse.R

Description

Computes the correlation between a composite and a vector of items.

Usage

1
fuseVec(r_mat, a, wt_a = rep(1, length(a)), output = "vec")

Arguments

r_mat

A correlation matrix.

a

The items used for composite A specified as a vector of column numbers.

wt_a

A vector containing the weights of each item in composite A.

output

Output can be set to "mat", to return a matrix made up of the newly generated correlations appened to the original correlation matrix.

Value

A vector of correlation coefficients.

Author(s)

Allen Goebl and Jeff Jones

References

Lord, F.M. & Novick, M.R. (1968). Statisticl theories of mental test scores., 97-98.

Examples

1
2
3
4
5
6
7
8
data(dls2007)
dat <- dls2007
rxx <- dat[1:4, 2:5]
items <- c(1,3)
wt_a <- c(2,1)

fuseVec(r_mat=rxx, a=items)
fuseVec(r_mat=rxx, a=items, wt_a=wt_a, output="mat")

iopsych documentation built on May 20, 2017, 3:20 a.m.

Search within the iopsych package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs in the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.