`prob` argument to monitor doesn't influence output
Open
Nobody has claimed this yet.
- Dominant language
- R
- Stars
- 1.1k
- Forks
- 266
- Avg merge
- 2h 56m
- Merged PRs (30d)
- 1
Description
Summary:
Monitor seems to output values for Q5/Q50/Q95 regardless of what is supplied as the value for the prob argument.
Reproducible Steps:
From the monitor examples section:
csvfiles <- dir(system.file('misc', package = 'rstan'),
pattern = 'rstan_doc_ex_[0-9].csv', full.names = TRUE)
fit <- read_stan_csv(csvfiles)
monitor(fit)
monitor(fit, probs = c(0.025, 0.25, 0.5, 0.75, 0.975))
Current Output:
Inference for the input samples (4 chains: each with iter = 200; warmup = 100):
Q5 Q50 Q95 Mean SD Rhat Bulk_ESS Tail_ESS
mu -0.3 0.1 0.4 0.1 0.2 1.01 348 229
sigma 0.9 1.1 1.5 1.2 0.2 1.01 227 178
z[1,1] -1.6 0.0 1.4 0.0 0.9 1.01 308 301
z[2,1] -1.4 0.1 1.7 0.1 1.0 1.01 329 246
z[3,1] -1.9 -0.1 1.7 -0.1 1.1 1.00 455 294
z[1,2] -1.7 0.0 1.5 0.0 1.0 1.01 278 138
z[2,2] -1.5 0.1 1.5 0.0 0.9 1.01 438 251
z[3,2] -1.6 0.1 1.9 0.1 1.0 1.02 344 124
alpha 0.0 0.4 1.6 0.5 0.5 1.01 354 116
lp__ -21.5 -17.2 -14.6 -17.5 2.3 1.03 117 208
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).
Expected Output:
Columns for the quantiles specified by the probs argument
RStan Version:
2.19.3
R Version:
3.6.1
Operating System:
Ubuntu 19.10
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the monitor examples and reproduce the issue using monitor(fit) and monitor(fit, probs = c(0.025, 0.25, 0.5, 0.75, 0.975)). Trace how the probs argument is handled and verify that the output columns match the supplied quantiles rather than fixed Q5, Q50, and Q95 columns.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- r
- Domain
- data
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100