Median, MATLAB in Statistics

Median

The median is defined only for a data set which has been sorted first, that means that the values are in order. The median of a sorted set of data values (n) is defined as the value in the middle, when n is odd; or the average of two values in the middle, when n is even. For illustration, for the vector [1 4 5 9 12], the middle value is 5. The function in a MATLAB is known as median:

>> median([1 4 5 9 12 ])

ans =

    5

Posted Date: 10/22/2012 7:04:07 AM | Location : United States







Related Discussions:- Median, Assignment Help, Ask Question on Median, Get Answer, Expert's Help, Median Discussions

Write discussion on Median
Your posts are moderated
Related Questions
Nested Structures: The nested structure is a structure in which at least one of the members is itself a structure. For illustration, a structure for the line segment may co

Functions which return Values versus printing: Also, the function which computes and returns values (throughout the output arguments) does not generally print them; that is le

fscanf function - file function: The fscanf reads matrix variable mat columnwise from the file specified by fid. The 'format' involves conversion characters much similar to th

Types of errors: There are some various kinds of errors which can occur in a program, that fall into the categories of run-time errors, syntax errors, and logical errors. T

Example of Functions which return values: Calling this function prints the circumference, since there is no way to store the value, hence, it can be used in following computat

Example of sorting strings: To sort a cell array of strings, also the sort function is used. The illustration is as follows, >> engcellnames = {'Chemical','Mechanical',.

Editor/Debugger: The MATLAB has numerous useful functions for debugging, and debugging can also be completed through its editor, which is known as the Editor/Debugger. Typi

Example of Core objects: The one core graphics object is a line that is also what the plot function produces. Here is an illustration of generating a line object, altering som

Function polyval - interpolation: The function polyval can then be used to compute the polynomial at particular values. For illustration, we could compute at every value in th

Execution of persistent variables: The functions can also be called from the script or from the Command Window, as shown here. For illustration, the functions are called first