fit_distribution_to_data
Fit a distribution family to a data range in Excel, write the result to a target cell, and optionally include parameter uncertainty for Monte Carlo risk modeling.
Instructions
ModelRisk: Fit a distribution family to a data range and write the result. 'family' is e.g. 'Normal', 'Lognormal', 'Beta', 'Gamma', 'Weibull' — the tool maps it to the catalogue function (VoseFit). Set uncertainty=True (the default) to include parameter uncertainty in the fitted distribution.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sheet | Yes | ||
| family | Yes | Distribution family, e.g. 'Normal'. | |
| dry_run | No | ||
| workbook | Yes | ||
| as_object | No | Write Vose<Family>FitObject(...) instead of the sampling Vose<Family>Fit(...). The OBJECT form is what compute_distribution / VoseMean / VosePercentile need to answer analytic questions about the fit; the sampling form is what a simulated model input needs. Default False (sampling). | |
| data_range | Yes | ||
| target_cell | Yes | ||
| uncertainty | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cell | Yes | ||
| formula | Yes | ||
| written | Yes | ||
| previous_formula | No |