score_squared_cosine | R Documentation |
Compute the relative importance of components for each trait (or variant) as defined in Tanigawa et al Nat Comm 2019.
score_squared_cosine(
svd_obj,
right_singular_vectors = FALSE,
component_prefix = "Component"
)
svd_obj |
A named list containing three matrices with u, d, and v as their names as in the output from base::svd() function. One can pass the results of base::svd(t(fit$C)) or tsvd_of_C_with_names(fit). Please note that this function assumes svd_obj$u and svd_obj$v corresponds to phenotypes and variants, respectively. |
right_singular_vectors |
An indicator variable to specify if we compute the score for right singular vector or not. If true, we compute the variant squared cosine score. If false, we compute phenotype squared cosine score. |
component_prefix |
A string used as a prefix for the column names corresponding to the latent variables |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.