Home > freetb4matlab > statistics > trimmean.m

trimmean

PURPOSE ^

%

SYNOPSIS ^

function a = trimmean(x, p, varargin)

DESCRIPTION ^

% -*- texinfo -*-
% @deftypefn {Function File} {@var{a} =} trimmean (@var{x}, @var{p})
%
% Compute the trimmed mean.
%
% The trimmed mean of @var{x} is defined as the mean of @var{x} excluding the
% highest and lowest @var{p} percent of the data.
%
% For example
%
% @example
% mean ([-inf, 1:9, inf])
% @end example
%
% is NaN, while
%
% @example
% trimmean ([-inf, 1:9, inf], 10)
% @end example
%
% excludes the infinite values, which make the result 5.
%
% @seealso{mean}
% @end deftypefn

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:
Generated on Sat 16-May-2009 00:04:49 by m2html © 2003