rating_curve_analysis
rating_curve_analysis(
stage,
discharge,
segments=1,
stage_bins=None,
min_stage=None,
max_stage=None,
sampler='DEMCz',
iterations=3000,
output_length=10000,
credible_level=0.9,
seed=12345,
number_of_chains=4,
thinning_interval=-1,
)Stage-discharge rating-curve frequency analysis.
Wraps the shared C++ RatingCurveAnalysis.
Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| stage | array_like | Observed stage values. | required |
| discharge | array_like | Observed discharge values. | required |
| segments | int | Number of rating-curve segments. | 1 |
| stage_bins | int | Number of stage grid points; when omitted, keeps the data-derived default. | None |
| min_stage | float | Lower stage-grid bound; data-derived when omitted. | None |
| max_stage | float | Upper stage-grid bound; data-derived when omitted. | None |
| sampler | ('DEMCz', 'DEMCzs', 'ARWMH', 'NUTS') | MCMC sampler. | "DEMCz" |
| iterations | int | Number of post-warmup MCMC iterations. | 3000 |
| output_length | int | Number of posterior samples used to build the credible band. | 10000 |
| credible_level | float | Credible-interval width. | 0.90 |
| seed | int | PRNG seed for the sampler. | 12345 |
| number_of_chains | int | Number of MCMC chains. | 4 |
| thinning_interval | int | MCMC thinning interval; -1 keeps the sampler’s own default. |
-1 |
Returns
| Name | Type | Description |
|---|---|---|
| dict | The predicted-discharge mode/mean curve and credible band across the stage grid. |