gendata {GrFA} | R Documentation |
Generate the grouped data.
Description
Generate the grouped data.
Usage
gendata(seed = 1, T = 50, N = rep(30, 5), r0 = 2, r = rep(2, 5),
Phi_G = 0.5, Phi_F = 0.5, Phi_e = 0.5, W_F = 0.5, beta = 0.1,
kappa = 1, case = 1)
Arguments
seed |
the seed used in |
T |
the number of time points. |
N |
a vector representing the number of variables in each group. |
r0 |
the number of global factors. |
r |
a vector representing the number of the local factors. Notice, the length of |
Phi_G |
hyperparameter of the global factors, default is 0.5, the value should between 0 and 1. |
Phi_F |
hyperparameter of the local factors, default is 0.5, the value should between 0 and 1. |
Phi_e |
hyperparameter of the errors, default is 0.5, the value should between 0 and 1. |
W_F |
hyperparameter of the correlation of local factors, only applicable in |
beta |
hyperparameter of the errors, default is 0.1. |
kappa |
hyperparameter of signal to noise ratio, default is 1. |
case |
the case of the data-generating process, default is 1, it can also be 2 and 3. |
Value
y |
a list of the data. |
G |
the global factors. |
F |
a list of the local factors. |
loading_G |
the global factor loadings. |
loading_F |
the local factor loadings. |
T |
the number of time points. |
N |
a vector representing the number of variables in each group. |
M |
the number of groups. |
r0 |
the number of global factors. |
r |
a vector representing the number of the local factors. |
case |
the case of the data-generating process. |
Examples
dat = gendata()
dat