Why do not return shrunken dispersion as the ultimate overdispersion?
- Dominant language
- R
- Stars
- 126
- Forks
- 18
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
I have a few questions related to the overdispersion returned. Hope you have time to give it a look. Thank you so much for a robust package for normalizing scRNA-seq data.
## Background
I'm working on the glmGamPoi package to fit my data to Negative Binomial distribution. The command I used:
```R
fit <- glmGamPoi::glm_gp(data = umi,
design = '~1',
col_data = data,
offset = log_umi,
size_factors = FALSE)
```
According to what I read on the paper and codebase, there are several kinds of overdispersion ($\theta$) along the processing of the method. Specifically, the shrunken quasi-likelihood overdispersion ($\theta_{SQL}$) is mentioned as the cleanest one with noises removed. Although it is quite computationally expensive, ultimately the primary overdispersion returned is the rough overdispersion (`disp_est`) (line 171) , which comes from [estimate_dispersions_roughly()][1].
https://github.com/const-ae/glmGamPoi/blob/95cffb79b02ce1239112d3c8b4adabfb448940bf/R/glm_gp_impl.R#L169-L176
## Question
1. Why not return $\theta_{SQL}$ as final overdispersions?
2. If returning the rough overdispersion on purpose, why have to spend resource to calculate $\theta_{SQL}$?
[1]: https://github.com/const-ae/glmGamPoi/blob/devel/R/glm_gp_impl.R#L68
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with R/glm_gp_impl.R around lines 169–176 and read estimate_dispersions_roughly() at the linked entry point. Trace where the rough and shrunken quasi-likelihood overdispersions are computed and consumed; done requires a maintainer decision on the intended returned value and the role of the SQL calculation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- r
- Domain
- data, machine-learning
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100