pub struct Posterior<const N: usize> {
pub quantiles: [[f64; 3]; N],
pub effective_draws: f64,
pub draws: usize,
pub failed: usize,
pub enough: bool,
}Expand description
What the weighted draws say of each unknown.
Fields§
§quantiles: [[f64; 3]; N]Each unknown’s 5%, 50% and 95% points (PROBABILITIES), in the unknowns’ order.
effective_draws: f64Kish’s effective sample size, (Σ wᵢ)² / Σ wᵢ².
draws: usizeThe draws made, failed ones included.
failed: usizeThe draws whose posterior couldn’t be had, or whose weight came out infinite or NaN; each
has no weight. A draw where the posterior is zero (log_target gives −∞) has no weight
either, but isn’t a failure.
enough: boolWhether Posterior::effective_draws reaches MIN_EFFECTIVE_DRAWS. It doesn’t weigh
Posterior::failed: many failed draws cut the posterior off where they fell, and
failed / draws says how many.
Trait Implementations§
Source§impl<'de, const N: usize> Deserialize<'de> for Posterior<N>
impl<'de, const N: usize> Deserialize<'de> for Posterior<N>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl<const N: usize> PartialEq for Posterior<N>
impl<const N: usize> PartialEq for Posterior<N>
impl<const N: usize> StructuralPartialEq for Posterior<N>
Auto Trait Implementations§
impl<const N: usize> Freeze for Posterior<N>
impl<const N: usize> RefUnwindSafe for Posterior<N>
impl<const N: usize> Send for Posterior<N>
impl<const N: usize> Sync for Posterior<N>
impl<const N: usize> Unpin for Posterior<N>
impl<const N: usize> UnsafeUnpin for Posterior<N>
impl<const N: usize> UnwindSafe for Posterior<N>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more