6 double diff,
mean = 0., fssm, tssm, sum_cube = 0., sum_four = 0.,
11 for (i = 0; i < n; ++i)
16 for (i = 0; i < n; ++i) {
18 sum_sq += diff * diff;
19 sum_cube += diff * diff * diff;
20 sum_four += diff * diff * diff * diff;
27 tssm = sqrt((
double)n) * sum_cube / pow(sum_sq, 1.5);
28 fssm = n * sum_four / (sum_sq * sum_sq);
31 fprintf(stdout,
" TESTS OF COMPOSITE DISTRIBUTIONAL HYPOTHESES\n");
32 fprintf(stdout,
" TEST1 TSM =%10.4f FSM =%10.4f\n", tssm, fssm);
float mean(IClass_statistics *statistics, int band)
Helper function for computing mean.
double * Cdhc_omnibus_moments(double *x, int n)