| plot.PLNPCAfamily {PLNmodels} | R Documentation |
Display the criteria associated with a collection of PLNPCA fits (a PLNPCAfamily)
## S3 method for class 'PLNPCAfamily'
plot(x, criteria = c("loglik", "BIC", "ICL"), annotate = TRUE, ...)
x |
an R6 object with class |
criteria |
vector of characters. The criteria to plot in c("loglik", "BIC", "ICL", "R_squared"). Default is c("loglik", "BIC", "ICL"). |
annotate |
logical: should the value of approximated R squared be added to the plot? |
... |
additional parameters for S3 compatibility. Not used |
Produces a plot representing the evolution of the criteria of the different models considered, highlighting the best model in terms of BIC and ICL (the greater, the better). These criteria have the form 'loglik - 1/2 * penalty' so that they are on the same scale as the model loglikelihood.
data(trichoptera) trichoptera <- prepare_data(trichoptera$Abundance, trichoptera$Covariate) myPCAs <- PLNPCA(Abundance ~ 1 + offset(log(Offset)), data = trichoptera, ranks = 1:5) ## Not run: plot(myPCAs) ## End(Not run)