Description Usage Arguments Value Alternative See Also Examples

The distribution can be extracted as:

a probability density function ("continuous").

a probability mass function ("discrete").

a series of equal-tailed confidence/credible intervals ("eti").

a series of highest density confidence/credible intervals ("hdi").

1 2 3 4 5 6 7 |

`object` |
Object specifying the distribution as samples: can be a Stanfit object, a matrix (columns represents parameters, rows samples) or a vector. |

`parName` |
Name of the parameter to extract. |

`type` |
Indicates how the distribution is summarised. |

`transform` |
Function to apply to the samples. |

`...` |
Arguments to pass to |

Dataframe

This function can notably be used to prepare the data for plotting fan charts when type = "eti" or "hdi".
In that case, the `ggdist`

package offers an alternative with `ggdist::stat_lineribbon()`

.

`extract_draws()`

for extracting draws of an object.

1 | ```
extract_distribution(runif(1e2), type = "continuous", support = c(0, 1))
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.