Developer Reference for Intel® oneAPI Math Kernel Library for C
Summary Statistics Task Computation Routines
Task computation routines calculate statistical estimates on the data provided and parameters held in the task descriptor. After you create the task and initialize its parameters, you can call the computation routines as many times as necessary. Table “Summary Statistics Estimates Obtained with vslSSCompute Routine” lists the respective statistical estimates.
Estimate |
Support of Observations Available in Blocks |
Description |
|---|---|---|
VSL_SS_MEAN |
Yes |
Computes the array of means. |
VSL_SS_SUM |
Yes |
Computes the array of sums. |
VSL_SS_2R_MOM |
Yes |
Computes the array of the 2 nd order raw moments. |
VSL_SS_2R_SUM |
Yes |
Computes the array of raw sums of the 2 nd order. |
VSL_SS_3R_MOM |
Yes |
Computes the array of the 3 rd order raw moments. |
VSL_SS_3R_SUM |
Yes |
Computes the array of raw sums of the 3 rd order. |
VSL_SS_4R_MOM |
Yes |
Computes the array of the 4 th order raw moments. |
VSL_SS_4R_SUM |
Yes |
Computes the array of raw sums of the 4 th order. |
VSL_SS_2C_MOM |
Yes |
Computes the array of the 2 nd order central moments. |
VSL_SS_2C_SUM |
Yes |
Computes the array of central sums of the 2 nd order. |
VSL_SS_3C_MOM |
Yes |
Computes the array of the 3 rd order central moments. |
VSL_SS_3C_SUM |
Yes |
Computes the array of central sums of the 3 rd order. |
VSL_SS_4C_MOM |
Yes |
Computes the array of the 4 th order central moments. |
VSL_SS_4C_SUM |
Yes |
Computes the array of central sums of the 4 th order. |
VSL_SS_KURTOSIS |
Yes |
Computes the array of kurtosis values. |
VSL_SS_SKEWNESS |
Yes |
Computes the array of skewness values. |
VSL_SS_MIN |
Yes |
Computes the array of minimum values. |
VSL_SS_MAX |
Yes |
Computes the array of maximum values. |
VSL_SS_VARIATION |
Yes |
Computes the array of variation coefficients. |
VSL_SS_COV |
Yes |
Computes a covariance matrix. |
VSL_SS_COR |
Yes |
Computes a correlation matrix. The main diagonal of the correlation matrix holds variances of the random vector components. |
VSL_SS_CP |
Yes |
Computes a cross-product matrix. |
VSL_SS_POOLED_COV |
No |
Computes a pooled covariance matrix. |
VSL_SS_POOLED_MEAN |
No |
Computes an array of pooled means. |
VSL_SS_GROUP_COV |
No |
Computes group covariance matrices. |
VSL_SS_GROUP_MEAN |
No |
Computes group means. |
VSL_SS_QUANTS |
No |
Computes quantiles. |
VSL_SS_ORDER_STATS |
No |
Computes order statistics. |
VSL_SS_ROBUST_COV |
No |
Computes a robust covariance matrix. |
VSL_SS_OUTLIERS |
No |
Detects outliers in the dataset. |
VSL_SS_PARTIAL_COV |
No |
Computes a partial covariance matrix. |
VSL_SS_PARTIAL_COR |
No |
Computes a partial correlation matrix. |
VSL_SS_MISSING_VALS |
No |
Supports missing values in datasets. |
VSL_SS_PARAMTR_COR |
No |
Computes a parameterized correlation matrix. |
VSL_SS_STREAM_QUANTS |
Yes |
Computes quantiles for streaming data. |
VSL_SS_MDAD |
No |
Computes median absolute deviation. |
VSL_SS_MNAD |
No |
Computes mean absolute deviation. |
VSL_SS_SORTED_OBSERV |
No |
Sorts the dataset by the components of the random vector ξ . |
Table “Summary Statistics Computation Method” lists estimate calculation methods supported by Intel® oneMKL . See the Intel® oneMKL Summary Statistics Application Notes document [SSNotes] for a detailed description of the methods.
Method |
Description |
|---|---|
VSL_SS_METHOD_FAST |
Fast method for calculation of the estimates: raw/central moments /sums , skewness, kurtosis, variation, variance-covariance/correlation /cross-product matrix min/max/quantile/order statistics partial variance-covariance median/mean absolute deviation |
VSL_SS_METHOD_FAST_USER_MEAN |
Fast method for calculation of the estimates given user-defined mean: central moments /sums of 2-4 order, skewness, kurtosis, variation, variance-covariance/correlation /cross-product matrix , mean absolute deviation |
VSL_SS_METHOD_1PASS |
One-pass method for calculation of estimates: raw/central moments /sums , skewness, kurtosis, variation, variance-covariance/correlation /cross-product matrix pooled/group covariance matrix |
VSL_SS_METHOD_TBS |
TBS method for robust estimation of covariance and mean |
VSL_SS_METHOD_BACON |
BACON method for detection of multivariate outliers |
VSL_SS_METHOD_MI |
Multiple imputation method for support of missing values |
VSL_SS_METHOD_SD |
Spectral decomposition method for parameterization of a correlation matrix |
VSL_SS_METHOD_SQUANTS_ZW |
Zhang-Wang (ZW) method for quantile estimation for streaming data |
VSL_SS_METHOD_SQUANTS_ZW_FAST |
Fast ZW method for quantile estimation for streaming data |
VSL_SS_METHOD_RADIX |
Radix method for dataset sorting |
You can calculate all requested estimates in one call of the routine. For example, to compute a kurtosis and covariance matrix using a fast method, pass a combination of the pre-defined parameters into the Compute routine as shown in the example below:
...
method = VSL_SS_METHOD_FAST;
task_params = VSL_SS_KURTOSIS|VSL_SS_COV;
...
status = vsldSSCompute( task, task_params, method );
After you complete computing the estimates, you can change the dataset either by:
copying the observations to memory, starting with the address available to the task
using one of the appropriate Editors to modify the pointer to the new dataset in the task.
To modify parameters of the task using the Task Editors, set the address of the targeted matrix of the observations or change the respective vector component indices. After you complete editing the task parameters, you can compute statistical estimates in the modified environment.
If the task completes successfully, the computation routine returns the zero status code. If an error is detected, the computation routine returns an error code. In particular, an error status code is returned in the following cases:
the task pointer is NULL
memory allocation has failed
the calculation has failed for some other reason