Changeset 20514
- Timestamp:
- Nov 3, 2008, 2:54:12 PM (18 years ago)
- File:
-
- 1 edited
-
trunk/psLib/src/math/psStats.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/math/psStats.c
r18876 r20514 13 13 * use ->min and ->max (PS_STAT_USE_RANGE) 14 14 * 15 * @version $Revision: 1.22 8$ $Name: not supported by cvs2svn $16 * @date $Date: 2008- 08-03 20:54:43$15 * @version $Revision: 1.229 $ $Name: not supported by cvs2svn $ 16 * @date $Date: 2008-11-04 00:54:12 $ 17 17 * 18 18 * Copyright 2006 IfA, University of Hawaii … … 651 651 // b) compute new mean and stdev 652 652 // Allocate a psStats structure for calculating the mean and stdev. 653 // XXX Can we just use this psStats structure to calculate the SAMPLE MEAN and STDEV?653 // XXX Can we just use this psStats structure to calculate the SAMPLE MEAN and STDEV? 654 654 // psStats *statsTmp = psStatsAlloc(PS_STAT_SAMPLE_MEAN | PS_STAT_SAMPLE_STDEV); 655 655 // vectorSampleMean(myVector, errors, tmpMask, maskVal, statsTmp); … … 932 932 for (long i = 0 ; i < myVector->n ; i++) { 933 933 if ((myVector->data.F32[i] < medianLo) || (myVector->data.F32[i] > medianHi)) { 934 // XXXX is this correct? is MASK_MARK safe?934 // XXXX is this correct? is MASK_MARK safe? 935 935 mask->data.U8[i] |= MASK_MARK; 936 936 psTrace(TRACE, 6, "Masking element %ld is %f\n", i, myVector->data.F32[i]); … … 2381 2381 psStatsOptions psStatsOptionFromString(const char *string) 2382 2382 { 2383 PS_ASSERT_STRING_NON_EMPTY(string, PS_STAT_NONE); 2384 2383 2385 #define READ_STAT(NAME, SYMBOL) \ 2384 2386 if (strcasecmp(string, NAME) == 0) { \ … … 2419 2421 2420 2422 psError(PS_ERR_BAD_PARAMETER_VALUE, true, "Unable to parse statistic: %s\n", string); 2421 return 0;2423 return PS_STAT_NONE; 2422 2424 } 2423 2425
Note:
See TracChangeset
for help on using the changeset viewer.
