WOLFRAM

gives the value of the biweight midvariance of the elements in list.

gives the value of the biweight midvariance with scaling parameter c.

Details

  • BiweightMidvariance is a robust dispersion estimator.
  • BiweightMidvariance is given by a weighted second-order central moment with Median as its center. Elements farther from the center have lower weights.
  • The width scale of the weight function is controlled by a parameter c. Larger c indicates more data values are included in the computation of the statistic, and vice versa.
  • For the list {x1,x2,,xn}, the value of the biweight midvariance estimator is given by , where , is Median[{x1,x2,,xn}], and is MedianDeviation[{x1,x2,,xn}].
  • BiweightMidvariance[list] is equivalent to BiweightMidvariance[list,9].
  • BiweightMidvariance[{{x1,y1,},{x2,y2,},}] gives {BiweightMidvariance[{x1,x2,}],BiweightMidvariance[{y1,y2,}],}.
  • BiweightMidvariance allows c to be any positive real number.

Examples

open allclose all

Basic Examples  (4)Summary of the most common use cases

BiweightMidvariance of a list:

Out[1]=1

BiweightMidvariance of columns of a matrix:

Out[1]=1

BiweightMidvariance of a list with scaling factor 8:

Out[1]=1

BiweightMidvariance of a list of dates:

Out[1]=1

Scope  (9)Survey of the scope of standard use cases

Exact input yields exact output:

Out[1]=1

Approximate input yields approximate output:

Out[1]=1
Out[2]=2

Biweight midvariance with different scaling parameters:

Out[1]=1
Out[2]=2

Biweight midvariance for a matrix gives columnwise estimate:

Out[1]=1

Biweight midvariance of a large array:

Out[1]=1
Out[2]=2

Find a biweight midvariance of a TimeSeries:

Out[2]=2

The biweight midvariance depends only on the values:

Out[3]=3

Biweight midvariance works with data involving quantities:

Out[1]=1
Out[2]=2

Compute biweight midvariance of dates:

Out[2]=2
Out[3]=3
Out[4]=4

Compute biweight midvariance of times:

Out[1]=1
Out[2]=2

List of times with different time zone specifications:

Out[3]=3
Out[4]=4

Applications  (5)Sample problems that can be solved with this function

Obtain a robust estimate of dispersion when extreme values are present:

Out[1]=1

Sample variance is heavily influenced by extreme values:

Out[2]=2

Identify periods of high volatility in stock data:

Out[2]=2

Smooth the data using the square root of a five-year moving biweight midvariance:

Out[4]=4

Compute biweight midvariance for slices of a collection of paths of a random process:

Choose a few slice times:

Out[3]=3

Plot biweight midvariances over these paths:

Out[4]=4

Find the biweight midvariance of the heights for the children in a class:

Out[2]=2
Out[3]=3

Plot the square root of the biweight midvariance with respect to the median:

Out[5]=5

Consider data from standard normal distribution with outliers modeled by another normal distribution with large spread:

Out[2]=2

Test the data against standard normal distribution:

Out[3]=3

Compute the biweight midvariance:

Out[4]=4

Remove outliers by picking data points that are within three times the square root of biweight midvariance from the sample median:

Out[7]=7

Test the new data against standard normal distribution:

Out[8]=8

Properties & Relations  (3)Properties of the function, and connections to other functions

Compute the biweight midvariance of a sample:

Out[9]=9

Values outside of the interval have no effect on the statistic. Here is the sample median and is the median absolute deviation. is a scaling parameter with default value equal to 9:

Out[4]=4

The shape of the weight function w(x) being used in computing biweight midvariance:

Out[5]=5

Multiply the smallest and the largest values in the sample by 2 and compute the biweight midvariance again:

Out[7]=7
Out[10]=10

BiweightMidvariance and Variance are dispersion estimators of data:

Resample the data to generate bootstrap estimates:

Compute the standard deviation/mean ratio of the bootstrap estimates for each estimator; smaller value indicates more accurate dispersion measure:

Out[4]=4
Out[5]=5

BiweightMidvariance converges to the second central moment for large values of the parameter c:

Out[2]=2
Out[3]=3

Possible Issues  (1)Common pitfalls and unexpected behavior

Biweight midvariance may be undefined for vectors of an even number of elements with a small scaling parameter:

Out[2]=2

For vectors of odd length and relatively small c, biweight midvariance might assume very large values:

Out[39]=39
Out[40]=40
Wolfram Research (2017), BiweightMidvariance, Wolfram Language function, https://reference.wolfram.com/language/ref/BiweightMidvariance.html (updated 2024).
Wolfram Research (2017), BiweightMidvariance, Wolfram Language function, https://reference.wolfram.com/language/ref/BiweightMidvariance.html (updated 2024).

Text

Wolfram Research (2017), BiweightMidvariance, Wolfram Language function, https://reference.wolfram.com/language/ref/BiweightMidvariance.html (updated 2024).

Wolfram Research (2017), BiweightMidvariance, Wolfram Language function, https://reference.wolfram.com/language/ref/BiweightMidvariance.html (updated 2024).

CMS

Wolfram Language. 2017. "BiweightMidvariance." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2024. https://reference.wolfram.com/language/ref/BiweightMidvariance.html.

Wolfram Language. 2017. "BiweightMidvariance." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2024. https://reference.wolfram.com/language/ref/BiweightMidvariance.html.

APA

Wolfram Language. (2017). BiweightMidvariance. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/BiweightMidvariance.html

Wolfram Language. (2017). BiweightMidvariance. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/BiweightMidvariance.html

BibTeX

@misc{reference.wolfram_2025_biweightmidvariance, author="Wolfram Research", title="{BiweightMidvariance}", year="2024", howpublished="\url{https://reference.wolfram.com/language/ref/BiweightMidvariance.html}", note=[Accessed: 29-April-2025 ]}

@misc{reference.wolfram_2025_biweightmidvariance, author="Wolfram Research", title="{BiweightMidvariance}", year="2024", howpublished="\url{https://reference.wolfram.com/language/ref/BiweightMidvariance.html}", note=[Accessed: 29-April-2025 ]}

BibLaTeX

@online{reference.wolfram_2025_biweightmidvariance, organization={Wolfram Research}, title={BiweightMidvariance}, year={2024}, url={https://reference.wolfram.com/language/ref/BiweightMidvariance.html}, note=[Accessed: 29-April-2025 ]}

@online{reference.wolfram_2025_biweightmidvariance, organization={Wolfram Research}, title={BiweightMidvariance}, year={2024}, url={https://reference.wolfram.com/language/ref/BiweightMidvariance.html}, note=[Accessed: 29-April-2025 ]}