View source: R/find_linear_dependent_columns.R
find_linear_dependent_columns | R Documentation |
Find linear dependent columns in a design matrix
find_linear_dependent_columns(mat, tol = 1e-12)
mat |
a matrix |
tol |
a double that specifies the numeric tolerance |
a list with vectors containing the indices of linearly dependent columns
The algorithm and function is inspired by the internalEnumLC
function in the 'caret' package (GitHub)
mat <- matrix(rnorm(3 * 10), nrow = 10, ncol = 3)
mat <- cbind(mat, mat[,1] + 0.5 * mat[,3])
find_linear_dependent_columns(mat) # returns list(c(1,3,4))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.