[英]Can I use poisson distribution as family in Generalized Additive Model (GAM) for continuous, non-negative data?
I am building a GAM with a data set which distribution resembles poisson-distributed data.我正在构建一个 GAM,其数据集的分布类似于泊松分布数据。 However, my data is continuous, ie, it contains information on tree volumes in cubic meters.但是,我的数据是连续的,即它包含以立方米为单位的树木体积信息。 So, when doing the GAM code in R (with mgcv library) can I use poisson as the family?那么,在做R中的GAM代码(带mgcv库)时,我可以使用泊松作为族吗? Or should I choose something else since the data is not count data?或者我应该选择别的东西,因为数据不是计数数据? I indeed found some threads discussing similar issues but they didn't provide an answer.我确实发现了一些讨论类似问题的线程,但他们没有提供答案。
My simplified example code with only one explanatory variable:我的简化示例代码只有一个解释变量:
gam_volumes <- gam(volumes_m3 ~ s(age, k=10), data=training, family=poisson)
I would use a Gamma distribution with log link for this;为此,我会使用带有日志链接的 Gamma 分布; this distribution will look like a Poisson (right skewed) but it is a continuous distribution.该分布看起来像泊松分布(右偏),但它是连续分布。 You can't have 0s in the Gamma but that's OK as a 0 volume tree isn't an observable tree. Gamma 中不能有 0,但这没关系,因为 0 卷树不是可观察的树。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.