StatisticFormula.Median Method (String)

.NET Framework (current version)
 

The median formula calculates the median of the data stored in a data series.

Namespace:   System.Web.UI.DataVisualization.Charting
Assembly:  System.Web.DataVisualization (in System.Web.DataVisualization.dll)

Public Function Median (
	inputSeriesName As String
) As Double

Parameters

inputSeriesName
Type: System.String

Name of the Series object that stores the data for which the median value is required.

Return Value

Type: System.Double

Median of all the data points in the given series.

If the named input series does not exist in the SeriesCollection at the time of the method call, an exception is thrown.

The following code demonstrates how to use this formula.

Dim result As Double = Chart1.DataManipulator.Statistics.Median("Series1")

.NET Framework
Available since 4.0
Return to top
Show: