MIDI Pipeline Reference Manual  2.8.3
statistics.h
1 /**********************************************************
2 ***********************************************************
3 * European Southern Observatory
4 * VLTI MIDI Data Reduction Software
5 *
6 * Module name: statistics.h
7 * Description: Contains the prototypes for all statistical
8 * computations
9 *
10 * History:
11 * 22-Dec-03 (csabet) Created
12 ***********************************************************
13 **********************************************************/
14 #ifndef _STATISTICS_H
15 #define _STATISTICS_H
16 
17 /**********************************************************
18 * Include files
19 **********************************************************/
20 
21 /**********************************************************
22 * Constant definitions
23 **********************************************************/
24 
25 /**********************************************************
26 * Type definitions
27 **********************************************************/
28 
29 /**********************************************************
30 * Global Variables
31 **********************************************************/
32 
33 /**********************************************************
34 * Function Prototypes
35 **********************************************************/
36 float signalPeak (
37  float *signal,
38  int start,
39  int end,
40  int *peakIndex);
41 
42 void removeDc (
43  int size,
44  float *inArray,
45  float *outArray);
46 
47 float signalMean (
48  float *signal,
49  int start,
50  int end);
51 
52 float signalVariance (
53  float *signal,
54  int start,
55  int end,
56  float *standDev);
57 
58 float signalMedian (
59  float *signal,
60  int start,
61  int end);
62 
63 void signalSortInt (
64  int *signal,
65  int start,
66  int end);
67 
68 void signalSort (
69  float *signal,
70  int start,
71  int end);
72 
73 void makeStats(
74  float *data,
75  int numdata,
76  float *mean,
77  float *rms);
78 
79 void midiGetLinearFit (
80  double *x,
81  double *y,
82  int ndata,
83  float sig,
84  int mwt,
85  float *a,
86  float *b,
87  float *siga,
88  float *sigb,
89  float *chi2,
90  float *q,
91  int *error);
92 
93 float midiGoodnessOfFit (
94  float a,
95  float x,
96  int *error);
97 
98 void gser (
99  float *gamser,
100  float a,
101  float x,
102  float *gln,
103  int *error);
104 
105 float gammln (
106  float xx);
107 
108 void gcf (
109  float *gammcf,
110  float a,
111  float x,
112  float *gln,
113  int *error);
114 
115 /*********************************************************/
116 #endif
117 /*********************************************************/
118 /*********************************************************/
119