stripe / rainier

Bayesian inference in Scala.
https://rainier.fit
Apache License 2.0
432 stars 51 forks source link

Models without observations #452

Closed avibryant closed 4 years ago

avibryant commented 4 years ago

This lets you construct a model with Model(x, y, ...) where x and y are random variables you want to use in posterior predictions, rather than representing likelihoods.

It also adds a .prior method to Model that strips away any observations, letting you easily run prior predictive checks.

cc @valencik

codecov-io commented 4 years ago

Codecov Report

Merging #452 into 0.3-dev will decrease coverage by 0.03%. The diff coverage is 35.71%.

Impacted file tree graph

@@             Coverage Diff             @@
##           0.3-dev     #452      +/-   ##
===========================================
- Coverage    51.32%   51.29%   -0.04%     
===========================================
  Files           72       72              
  Lines         2899     2903       +4     
  Branches       161      169       +8     
===========================================
+ Hits          1488     1489       +1     
- Misses        1411     1414       +3
Impacted Files Coverage Δ
...c/main/scala/com/stripe/rainier/plot/Jupyter.scala 0% <ø> (ø) :arrow_up:
...main/scala/com/stripe/rainier/compute/Target.scala 89.88% <ø> (ø) :arrow_up:
...src/main/scala/com/stripe/rainier/core/Model.scala 60.78% <35.71%> (-3.05%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 959bbab...2f484fd. Read the comment docs.