invert4geom.regional_misfit_uncertainty#
- regional_misfit_uncertainty(runs, sample_gravity=False, parameter_dict=None, region=None, plot=True, plot_region=None, true_regional=None, coast=False, weight_by=None, **kwargs)[source]#
Create a stochastic ensemble of regional gravity anomalies by sampling the constraints, gravity, or parameters within their respective distributions and calculate the cell-wise (weighted) statistics of the ensemble.
- Parameters:
runs (int) â number of runs to perform
sample_gravity (bool, optional) â choose to sample the gravity data from a normal distribution with a mean of each points value and a standard deviation set by the uncert column, by default False
parameter_dict (dict[str, Any] | None, optional) â dictionary of parameters passes to regional_separation with the uncertainty distributions defined, by default None
region (tuple[float, float, float, float] | None = None,) â region to calculate statistics within, by default None
plot (bool, optional) â show the results, by default True
plot_region (tuple[float, float, float, float] | None, optional) â clip the plot to a region, by default None
true_regional (xarray.DataArray | None, optional) â if the true regional misfit is known, will make a plot comparing the results, by default None
coast (bool, optional) â whether to plot coastlines, by default False
weight_by (str | None, optional) â how to weight the models, by default None
kwargs (
Any)
- Return type:
- Returns:
stats_ds (xarray.Dataset) â a dataset with the cell-wise statistics of the ensemble of regional gravity
sampled_param_dict (dict[str, typing.Any]) â a dictionary of sampled parameter values.