xdem.spatialstats.two_step_standardization#
- xdem.spatialstats.two_step_standardization(dvalues, list_var, unscaled_error_fun, spread_statistic=<function nmad>, fac_spread_outliers=7)[source]#
Standardize the proxy differenced values using the modelled heteroscedasticity, re-scaled to the spread statistic, and generate the final standardization function.
- Parameters:
dvalues (
ndarray
[Any
,dtype
[floating
[Any
]]]) – Proxy values as array of size (N,) (i.e., differenced values where signal should be zero such as elevation differences on stable terrain)list_var (
list
[ndarray
[Any
,dtype
[floating
[Any
]]]]) – List of size (L) of explanatory variables array of size (N,)unscaled_error_fun (
Callable
[[tuple
[Union
[Buffer
,_SupportsArray
[dtype
[Any
]],_NestedSequence
[_SupportsArray
[dtype
[Any
]]],bool
,int
,float
,complex
,str
,bytes
,_NestedSequence
[Union
[bool
,int
,float
,complex
,str
,bytes
]]],...
]],ndarray
[Any
,dtype
[floating
[Any
]]]]) – Function of the spread with explanatory variables not yet re-scaledspread_statistic (
Callable
[[ndarray
[Any
,dtype
[floating
[Any
]]]],floating
[Any
]]) – Statistic to be computed for the spread; defaults to nmadfac_spread_outliers (
float
|None
) – Exclude outliers outside this spread after standardizing; pass None to ignore.
- Return type:
tuple
[ndarray
[Any
,dtype
[floating
[Any
]]],Callable
[[tuple
[Union
[Buffer
,_SupportsArray
[dtype
[Any
]],_NestedSequence
[_SupportsArray
[dtype
[Any
]]],bool
,int
,float
,complex
,str
,bytes
,_NestedSequence
[Union
[bool
,int
,float
,complex
,str
,bytes
]]],...
]],ndarray
[Any
,dtype
[floating
[Any
]]]]]- Returns:
Standardized values array of size (N,), Function to destandardize