Select the number of factors and the rank of coefficient matrix in the covariate-augmented overdispersed Poisson factor model

selectParams(
  X_count,
  Z,
  multiFac = rep(1, nrow(X_count)),
  q_max = 15,
  r_max = 24,
  threshold = c(0.1, 0.01),
  verbose = TRUE,
  ...
)

Arguments

X_count

a count matrix, the observed count matrix.

Z

an optional matrix, the covariate matrix; default as a full-one column vector if there is no additional covariates.

multiFac

an optional vector, the normalization factor for each unit; default as full-one vector.

q_max

an optional string, specify the upper bound for the number of factors; default as 15.

r_max

an optional integer, specify the upper bound for the rank of the regression coefficient matrix; default as 24.

threshold

an optional 2-dimensional positive vector, specify the the thresholds that filters the singular values of beta and B, respectively.

verbose

a logical value, whether output the information in iteration.

maxIter

the maximum iteration of the VEM algorithm. The default is 30.

joint_opt_beta

a logical value, whether use the joint optimization method to update bbeta. The default is FALSE, which means using the separate optimization method.

fast_svd

a logical value, whether use the fast SVD algorithm in the update of bbeta; default is TRUE.

Value

return a named vector with names `hr` and `hq`, the estimated rank and number of factors.

Details

The threshold is to filter the singular values with low signal, to assist the identification of underlying model structure.

References

None

See also