dfee_nb: Marginal First-Exposure Effects for One-Inflated...

View source: R/dfee_nb.R

dfee_nbR Documentation

Marginal First-Exposure Effects for One-Inflated Zero-Truncated Negative Binomial model

Description

This function is used internally by dfee. The function computes analytical derivatives of the FEE with respect to covariates, and uses discrete differences for binary indicators.

Usage

dfee_nb(b, g, a, X, Z, dummies)

Arguments

b

A numeric vector of estimated coefficients for the rate.

g

A numeric vector of estimated coefficients for inflation.

a

A dispersion parameter from the negative binomial model.

X

A numeric matrix of covariates for the rate.

Z

A numeric matrix of covariates for inflation.

dummies

A character vector naming the binary (dummy) variables to compute marginal effects for.

Value

A matrix of marginal first-exposure effects. Each column corresponds to a covariate, and each row corresponds to an observation in the data.

See Also

dfee, fee_negbin, dfee_pois


fee documentation built on Aug. 8, 2025, 7:45 p.m.

Related to dfee_nb in fee...