1 |
– |
/* Copyright (c) 1991 Regents of the University of California */ |
2 |
– |
|
1 |
|
#ifndef lint |
2 |
< |
static char SCCSid[] = "$SunId$ LBL"; |
2 |
> |
static const char RCSid[] = "$Id$"; |
3 |
|
#endif |
6 |
– |
|
4 |
|
/* |
5 |
|
* Basic linear regression calculation. |
6 |
|
*/ |
7 |
|
|
8 |
+ |
#include "copyright.h" |
9 |
+ |
|
10 |
+ |
#include <math.h> |
11 |
+ |
|
12 |
|
#include "linregr.h" |
13 |
|
|
14 |
|
|
15 |
+ |
void |
16 |
|
lrclear(l) /* initialize sum */ |
17 |
|
register LRSUM *l; |
18 |
|
{ |
21 |
|
} |
22 |
|
|
23 |
|
|
24 |
+ |
int |
25 |
|
flrpoint(x, y, l) /* add point (x,y) to sum */ |
26 |
|
double x, y; |
27 |
|
register LRSUM *l; |
35 |
|
} |
36 |
|
|
37 |
|
|
38 |
+ |
int |
39 |
|
lrfit(r, l) /* compute linear regression */ |
40 |
|
register LRLIN *r; |
41 |
|
register LRSUM *l; |