summarise_regions()#
- liesel_gam.summarise_regions(term, samples, newdata=None, which='mean', polys=None, labels=None, quantiles=(0.05, 0.5, 0.95), hdi_prob=0.9)[source]#
Summarises a discrete spatial term.
- Parameters:
term (
RITerm|MRFTerm|StrctTerm) – The term to summarise, aRITermorMRFTerm.samples (
Mapping[str,Array|ndarray|bool|number|bool|int|float|complex]) – Dictionary of posterior samples. Must contain samples for the term’s coefficient.newdata (
Position(dict[str,Any]) |None|Mapping[str,Array|ndarray|bool|number|bool|int|float|complex], default:None) – Dictionary of covariate data at which to summarise the term. IfNone, uses the unique clusters known to the term.which (
Literal['mean','sd','var','hdi_low','hdi_high','q_0.05','q_0.5','q_0.95'] |Sequence[Literal['mean','sd','var','hdi_low','hdi_high','q_0.05','q_0.5','q_0.95']], default:'mean') – Sequence of strings, indicating the summary quantities to include.polys (
Mapping[str,Array|ndarray|bool|number|bool|int|float|complex] |None, default:None) – Dictionary of arrays. The keys of the dict are the region labels. The corresponding values define the region by defining polygons. The neighborhood structure can be inferred from this polygon information.labels (
CategoryMapping|Sequence[str] |None, default:None) – Custom mapping to use for mapping between string labels and integer codes.quantiles (
Sequence[float], default:(0.05, 0.5, 0.95)) – Probability levels of quantiles to include.hdi_prob (
float, default:0.9) – Probability level for highest posterior density interval.
- Return type: