This function takes a matrix (m), a lambda value (lambda), and the number
of desired eigenvectors (k) as input. It then computes
eigenvectors 1 to k, penalized by the supplied lambda.
Usage
unsmoothed_penalized_EV(m, lambda, k)
Value
Returns eigenvectors 1 to k for the specified lambda value.
Arguments
m
A matrix generated from a large dataset.
lambda
A numeric vector of lambda values to use for the penalty.
k
The number of eigenvectors we consider in the analysis.
# Generate a small matrix for testingm <- matrix(rnorm(100), nrow = 10)
# Call function (using matrix, lambda, and k)unsmoothed_penalized_EV(
m = m,
lambda = 1,
k = 2)