generator_PLN: Simulate count data under the Poisson log-Normal model

View source: R/gener_data.R

generator_PLNR Documentation

Simulate count data under the Poisson log-Normal model

Description

Simulate count data under the Poisson log-Normal model

Usage

generator_PLN(Sigma, covariates = NULL, n = 50, norm = FALSE)

Arguments

Sigma

Covariance matrix of the normal hidden layer of parameters

covariates

a data.frame or matrix containing data covariates. If not NULL, defines the number of simulated rows.

n

number of rows to simulate

norm

should the parameters be normalized ?

Value

  • if norm=FALSE Y: the simulated counts

  • if norm=TRUE

    • Y:simulated counts

    • U: the normalized Gaussian parameters

Examples

G<-generator_graph(p=10,graph="tree")
sigma<-generator_param(G=G)$sigma
generator_PLN(as.matrix(sigma))

Rmomal/EMtree documentation built on Dec. 14, 2024, 8:16 a.m.