Menu

mean_remext()

Added in Version 1.0
Discontinued in Version 1.1

Usage

mean_remext(numlist, highextremes=1, lowextremes=1)
  • Returns the mean of a list after extremes have been removed.
  • numlist must be a list object containing only real numbers.
  • highextremes is optional and determines the number of extremes on the high end of the list to remove. 1 is the default if the argument is omitted, but it can be changed to any positive number or 0.
  • lowextremes is optional and determines the number of extremes on the low end of the list to remove. 1 is the default if the argument is omitted, but it can be changed to any positive number or 0.
  • If you do not require extremes to be removed, consider using [mean()].

Examples

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

from pydoodles import mean_remext
mean_remext([1, 2, 3])
2.0
mean_remext([1, 2, 3], 0, 1)
2.5
mean_remext([1, 2, 3], 0, 2)
3.0
mean_remext([1, 2, 3], 1, 0)
1.5
mean_remext([1, 2, 3, 4, 5, 6, 7], 2, 1)
3.5
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Removal

mean_remext() has been merged into mean() as of version 1.1.


Related

Blog: 2013/05/11-released
Wiki: mean()