meridian.model.prior_sampler.PriorDistributionSampler
Stay organized with collections
Save and categorize content based on your preferences.
A callable that samples from a model spec's prior distributions.
meridian.model.prior_sampler.PriorDistributionSampler(
meridian: 'model.Meridian'
)
Methods
__call__
View source
__call__(
n_draws: int, seed: (int | None) = None
) -> None
Draws samples from prior distributions.
| Args |
n_draws
|
Number of samples drawn from the prior distribution.
|
seed
|
Used to set the seed for reproducible results. For more information,
see PRNGS and seeds.
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-12-09 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-12-09 UTC."],[],["The `PriorDistributionSampler` samples from a model's prior distributions. It includes methods to compute tensors for `beta_m` and `beta_rf` via `get_roi_prior_beta_m_value` and `get_roi_prior_beta_rf_value`, respectively. The `__call__` method generates samples from the prior distributions, returning an Arviz `InferenceData` object. This method takes the number of samples (`n_draws`) and an optional seed for reproducibility as inputs.\n"]]