Dundas Chart for Windows Forms
Mean Formula
See Also Send comments on this topic.
Formula Reference > Statistical Formulas > Mean Formula



Glossary Item Box

Overview

Enterprise Edition Only Feature.

This formula returns the average, or mean, of data stored in a data series.

Applying the Formula

All statistical formulas are calculated using the Statistics class, and the following table describes how to use its Mean method to get an average.

 

Value/Description Example
Formula Name: Mean Statistics.Mean ("Series1")
Parameters:
  1. inputSeriesName: The name of the Series object that stores the data for which an average is required.
Statistics.Mean("Series1")
Return: A double that represents the average of all the data points in the given series.

-

 

Note
Make sure that all data points have their XValue property set, and that their series'  XValueIndexed property has been set to false.

Statistical Interpretation

The average, or mean, is the sum of all values divided by the number of values.

Please note that it is the first Y value (Y1) of all data points that are used to calculate the mean.

 

Figure 1: A line type chart, with a Strip Line on the Y-axis representing the Mean.

 

Example

This example demonstrates how to get the average of the data points in a series named "Series1". Note that the Y1 value of the data points is used.

Visual Basic Copy Code
Imports Dundas.Charting.WinControl
  ...
  
Dim result As Double = Chart1.DataManipulator.Statistics.Mean("Series1")

C# Copy Code
using Dundas.Charting.WinControl;
  ...
  
double result = Chart1.DataManipulator.Statistics.Mean("Series1");

See Also

©2009. All Rights Reserved.