View source: R/bage_ssvd-constructors.R
| ssvd | R Documentation |
Create an object of class "bage_ssvd" to
hold results from a scaled Singular Value Decomposition
(SVD) with n_comp components.
ssvd(data)
data |
A data frame. See Details for description. |
data has the following columns:
version Vintage of data
type Type of decomposition. Choices are "total",
"joint", and "indep".
labels_age Age labels for individual rows of
matrices within matrix and individual elements
of vectors within offset.
labels_sexgender Sex/gender labels for individual rows of
matrices within matrix and individual elements
of vectors within offset, or NULL.
NULL when sexgender is "total", since in
this case results average across sexes/genders.
matrix List column of sparse matrices.
Must have rownames.
Must not have NAs. When type is "total" or "joint",
each matrix has n_comp columns. When "type" is "indep",
each matrix has 2 * n_comp columns.
offset List column of vectors.
Must have names, which
are identical to the rownames of the corresponding
element of matrix.
data would normally be constructed using functions
in package bssvd.
An object of class "bage_ssvd".
Scaled SVDs Overview of scaled SVDs implemented in bage
SVD() Prior based on scaled SVD
ssvd(data_wmd)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.