ComreySolve: ComreySolve

View source: R/ComreySolve.R

ComreySolveR Documentation

ComreySolve

Description

Given a square matrix, such that the matrix is the outer product of a single vector with itself (except for the diagonal, which is ignored), determine the vector that was originally used. ComreySolve also has a helper function called ComreyIterate. There isn't really any reason why you would use Comrey iterate by itself.

Usage

ComreySolve(M, precision = 0.005)

Arguments

M

A square matrix.

precision

The level of error at which the process will stop iterating and return an answer. Error is measured as "change in output vector between two iteration steps."

Value

A single vector of numbers representing the vector that was originally used to create M.

Note

NOTE TO SELF: I really need to go back and re-read Comrey's paper to make sure I have done this right!

Author(s)

Alastair Jamieson Lane. <aja107@math.ubc.ca>

Benjamin Grant Purzycki. <bgpurzycki@alumni.ubc.ca>

References

The Minimum Residual method of Factor Analysis. Comrey, A.L. Psychological Reports, (1962) 11:15-18

Examples

x<- 1:5
mat<- x \%*\% t(x)
y<- ComreySolve(mat)

alastair-JL/AnthroTools documentation built on Aug. 29, 2024, 9:36 a.m.