robust.scale.mad()

statsmodels.robust.scale.mad

statsmodels.robust.scale.mad(a, c=0.67448975019608171, axis=0, center=<function median>) [source]

The Median Absolute Deviation along given axis of an array

Parameters:

a : array-like

Input array.

c : float, optional

The normalization constant. Defined as scipy.stats.norm.ppf(3/4.), which is approximately .6745.

axis : int, optional

The defaul is 0. Can also be None.

center : callable or float

If a callable is provided, such as the default np.median then it is expected to be called center(a). The axis argument will be applied via np.apply_over_axes. Otherwise, provide a float.

Returns:

mad : float

mad = median(abs(a - center))/c

© 2009–2012 Statsmodels Developers
© 2006–2008 Scipy Developers
© 2006 Jonathan E. Taylor
Licensed under the 3-clause BSD License.
http://www.statsmodels.org/stable/generated/statsmodels.robust.scale.mad.html

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部