Compute moments on worksheet data
1. moments ix:=Col(1);
2. moments ix:=Col(1) mean:=mymean;
Please refer to the page for additional option switches when accessing the x-function from script
Display Name |
Variable Name |
I/O and Type |
Default Value |
Description |
---|---|---|---|---|
Input | ix |
Input vector |
|
Specifies the input data range |
Mean | mean |
Output double |
|
The variable specifies the output for the arithmetic average. |
Standard Deviation | sd |
Output double |
|
The variable specifies the output for the standard deviation, which is a statistical measure of the distance a quantity is likely to lie from the average value of a group of data. |
SE of Mean | se |
Output double |
|
The variable specifies the output for the standard error of the mean, which is used to estimate the deviation of the population mean. |
Number of Observations | n |
Output int |
|
The variable specifies the output for the number of valid observations |
Sum | sum |
Output double |
|
The variable specifies the output for the arithmetic sum of selected dataset |
Skewness | skewness |
Output double |
|
The variable specifies the output for skewness, which reveals the symmetry of sample distribution. A positive skewness implies the distribution curve skew to right while a negative value indicates the curve skew to left |
Kurtosis | kurtosis |
Output double |
|
The variable specifies the output for kurtosis, which indicates how flat or peaked a distribution is. Negative values correspond to flat distributions, while positive values correspond to peaked distributions. |
Coefficient of Variation | cv |
Output double |
|
The variable specifies the coefficient of variation, which gives a measure of how dispersed a dataset is. This measure can be used to compare distributions of different sizes and with different means. |
The "moments" command displays the mean, standard deviation, and other summary statistics of a given dataset. moments are used to describe certain basic features of the data in a study.
In the context of statistical analysis, moments include measures such as mean, standard deviation, standard error, kurtosis, skewness, and coefficient of variation.
1. List all input and output results of descriptive statistics of given dataset, we assume data are put in 1st column of active worksheet.
In Command Window, type the following:
moments ix:=col(a);
2. To return the standard deviation of given dataset from the Command Window, type the following (we assume that the data are put in 1st column of active worksheet):
moments ix:=col(a) sd:=mysd; mysd=
Let for
denotes the input values, then:
1. Mean is computed using the following equation:
2. Standard deviation is computed as follows:
3. Standard error is computed as:
4. Sample size is the total number of valid values in a data set
5. Sum is computed using following equation:
8. Coefficient of variance is computed as:
Silverman, B.W. (1986), Density Estimation for Statistics and Data Analysis. New York: Chapman and Hall.
Tukey, J.W. (1977), Exploratory Data Analysis. Reading, MA: Addison-Wesley.
Erickson, B.H. and Nosanchuk, T.A. (1992) Understanding Data. Second Edition. Buckingham: Open University Press.
stats, quantiles, rowstats, rowquantiles
Keywords:summary statistics, mean, median, standard deviation, skewness, kurtosis