Skip to content

curvefit.initializer.initializer.PriorInitializerComponent

A component of a prior initializer for a model

For a given solver, model and parameter set there are a number of strategies to get information to inform a prior for a later model fit. This base class is used to build prior initializer components, that is, objects that extract information from models that have already been run to get well-informed priors for later runs.

Prior initializer components can have two types: priors that are extracted from the analysis of a joint model run (one model run with > 1 group), and priors that are extracted from the analysis of a bunch of individual models runs (many models runs with 1 group each). See the documentation on JointPriorInitializerComponent and IndividualPriorInitializerComponent.

Attributes

  • self.component_type (str, None): type of component, overridden in subclasses ("joint" or "individual")

Methods

_extract_prior

A method to extract prior information from a solver or a list of solvers. Overridden in subclasses.

  • solver (List[Solver], curvefit.core.solver.Solver): solver or list of solvers that have fit models to data using a parameter set

_update_parameter_set

A method to update a parameter set given information that was extracted about the priors from the solvers.

  • solver (List[Solver], curvefit.core.solver.Solver): see above
  • parameter_set_prototype (curvefit.core.parameter.ParameterSet): a parameter set that will be updated with new prior information