bebi103.stan.check_energy

bebi103.stan.check_energy(samples, e_bfmi_rule_of_thumb=0.3, quiet=False, return_diagnostics=False)

Checks the energy-Bayes fraction of missing information (E-BFMI)

Parameters
  • samples (ArviZ InferenceData instance) – Contains samples to be checked. Must contain both posterior and sample_stats.

  • e_bfmi_rule_of_thumb (float, default 0.3 (as per cmdstan)) – Rule of thumb value for E-BFMI. If below this value, there may be cause for concern.

  • quiet (bool, default False) – If True, do no print diagnostic result to the screen.

  • return_diagnostics (bool, default False) – If True, return both a Boolean about whether the diagnostic passed and a data frame containing results about the E-BMFI tests. Otherwise, only return Boolean if the test passed.

Returns

  • passed (bool) – Return True if test passed. Return False otherwise.

  • e_bfmi_diagnostics (DataFrame) – DataFrame with information about which chains had problematic E-BFMIs.