Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Little fixes #31

Merged
merged 18 commits into from
Apr 24, 2023
Merged

Little fixes #31

merged 18 commits into from
Apr 24, 2023

Conversation

jcblemai
Copy link
Collaborator

  • Argument to set inference_job time limit
  • fix ground truth env variable

saraloo
saraloo previously approved these changes Apr 19, 2023
jcblemai and others added 12 commits April 20, 2023 17:03
Updated some likelihood functions and added lognormal
- updated sqrtnorm to have a constant standard deviation not constant coefficient of variation. Created new distribution sqrtnorm_cov
- for norm_cov and sqrtnorm_cov, standard deviation is scaled by the SIMULATION, not the observation, since the simulated value is the mean of the distribution
-added the lognormal distribution. The MLE/mode of this distribution is the simulated value. All zeros in the data must be converted into "1" first to avoid infinite values for the log
Before if add_one was one we always added one to all zero simulation values. The problem with this is that if the data was also zero, this is artificially moving the model away from the data and lowering the likelihood. In addition, having data values of zero is also a problem for some likelihood functions. Now, we do something slightly more nuanced.
*  If the model and data are both zero at a timepoint, we assign a likelihood of 1.
* If only the model is zero but data is non-zero, if add_one is TRUE we add one to model value and calculate likelihood.
* If the model is non-zero, then the likelihood is evaluated as normal UNLESS the function is lognormal, and then we add one to the observed data
Updated tests to include lognormal and to include check that when data and simulation are both zero, log likelihood is zero (the highest likelihood possible)
@jcblemai jcblemai requested a review from saraloo April 24, 2023 16:02
@shauntruelove shauntruelove merged commit 59938f9 into main Apr 24, 2023
1 check passed
@jcblemai jcblemai deleted the little-fixes branch April 25, 2023 13:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants