sample_prior | R Documentation |

Samples from a prior
distribution with parameters defined in `prior`

. The result can be plotted
using the `plot`

function.

```
sample_prior(
method = c("hs", "lasso"),
prior = switch(method, lasso = c(df = 1, scale = 1), hs = c(df = 1, df_global = 1,
df_slab = 4, scale_global = 1, scale_slab = 2, par_ratio = NULL)),
iter = 1000
)
```

`method` |
Character string, indicating which prior to sample from.
Default: first element of |

`prior` |
Numeric vector, specifying the prior to use. See brma for more details. |

`iter` |
A positive integer specifying the number of iterations to sample. Default: 1000 |

NULL, function is called for its side-effect of plotting to the graphics device.

```
sample_prior("lasso", iter = 10)
```

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.