coef.PLNfit: Extract model coefficients

View source: R/PLNfit-S3methods.R

coef.PLNfitR Documentation

Extract model coefficients

Description

Extracts model coefficients from objects returned by PLN() and its variants

Usage

## S3 method for class 'PLNfit'
coef(object, type = c("main", "covariance"), ...)

Arguments

object

an R6 object with class PLNfit

type

type of parameter that should be extracted. Either "main" (default) for

B

or "covariance" for

\Sigma

...

additional parameters for S3 compatibility. Not used

Value

A matrix of coefficients extracted from the PLNfit model.

See Also

sigma.PLNfit(), vcov.PLNfit(), standard_error.PLNfit()

Examples

data(trichoptera)
trichoptera <- prepare_data(trichoptera$Abundance, trichoptera$Covariate)
myPLN <- PLN(Abundance ~ 1 + offset(log(Offset)), data = trichoptera)
coef(myPLN) ## B
coef(myPLN, type = "covariance") ## Sigma

PLNmodels documentation built on Aug. 24, 2023, 5:11 p.m.