stan-dev / stan-dev/posterior

Pretty print diagnostic summaries

Open
#255 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature interface
Dominant language
R
Stars
171
Forks
26
Avg merge
2d 18h
Merged PRs (30d)
3

Description

summarise_draws() computes the summaries and outputs a tibble which is useful, but for notebooks it would be nice to have pretty printed output. I like the rstan::monitor() output

> monitor(samp, probs = c(0.25, 0.5, 0.75), digits_summary = 2)
Inference for the input samples (1 chains: each with iter = 2001; warmup = 1000):

     Q5 Q50 Q95 Mean  SD  Rhat Bulk_ESS Tail_ESS
V1 -0.9 0.2 1.5  0.2 0.8  1.14        5       15
V2 -0.9 0.2 1.5  0.2 0.8  1.15        5       18

For each parameter, Bulk_ESS and Tail_ESS are crude measures of 
effective sample size for bulk and tail quantities respectively (an ESS > 100 
per chain is considered good), and Rhat is the potential scale reduction 
factor on rank normalized split chains (at convergence, Rhat <= 1.05).

Specifically, for the possibility to define the number of digits and always rounding the ESSs.

It seems pillar is not flexible enough for formatting, so it seems monitor() style text output would be easier. It would be cool to have another function for pretty tables, but there are benefits for the simpler monitor() style output, too.

This is related to several earlier issues #44, #97, #120, #185 which mention only some parts of this issue

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with summarise_draws() and review the related issues #44, #97, #120, and #185, along with the limitations of pillar mentioned here. Compare the requested digit control and ESS rounding with the rstan::monitor() style; done requires an agreed approach for the pretty-printed output and its interface.

Written by the indexing model from the issue text.

Assessment

Tech stack
r
Domain
data
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.