SBC histogram
There is a code for making the histogram for the SBC paper in the sbc_histogram branch.
@avehtari Can this be closed given https://github.com/stan-dev/bayesplot/issues/178 and https://github.com/stan-dev/bayesplot/pull/179? Aren't the SBC plots a subset of the new diagnostic plots?
That issue and that pull request so far discuss functions which would take chains as an argument, and ranks are computed by combining the chains. In SBC the prior draw and posterior draws in one iteration are forming one rank, and sbc_histogram would probably take these ranks as argument (and the extra thing in the plotting is adding the interval butterfly behind).
Both mcmc_rank_histogram and sbc_histogram could use the same code for the plotting part, but it's not clear whether mcmc_rank_histogram should have that interval butterfly, ecdf difference with envelope is better for intervals. There would be more code to share in ecdf difference with envelope plot, but again the input arguments are different.
Ok, that makes sense, thanks.
If you don't mind, I can try merging your code from the SBC paper with my attempt?
If the code on Dan's branch that he refers to above is useful go for it. Not sure if that's what you mean. If there's other code in with the paper that's useful I'm sure that's fine too.
You can definitely take whatever we already have in the code for the simple sbc plot in rstan and put it into this new bayesplot function with your additions. Up to you what you want to take and what you want to rewrite.