File: lfstruc.h

package info (click to toggle)
cufflinks 1.3.0-2
  • links: PTS, VCS
  • area: non-free
  • in suites: wheezy
  • size: 3,864 kB
  • sloc: cpp: 48,999; ansic: 12,297; sh: 3,381; python: 432; makefile: 209
file content (102 lines) | stat: -rw-r--r-- 2,337 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
/*
 *   Copyright (c) 1998-2000 Lucent Technologies.
 *   See README file for details.
 *
 *
 *
 *   Structures, typedefs etc used in Locfit
 */

typedef char varname[64];

/*
 *  Define the vari type for locfit variables and related macros.
 *  For the C version, an enhanced vari type is needed;
 *  for other versions a simple structure suffices.
 */
#ifdef CVERSION

typedef struct {
  varname name;
  INT n, bytes, mode, stat;
  double *dpr; } vari;
#define checkvarlen(v,n,name,mode) (createvar(name,STSYSTEM,n,mode))
#define vmode(v) ((v)->mode)

#else

typedef struct {
  INT n;
  double *dpr;
} vari;
#define viptr(v,i) (&(v)->dpr[i])
#define checkvarlen(v,len,name,mode) \
   ((((v)!=NULL) && (vlength(v) >= (len))) ? (v) : createvar((name),0,(len),(mode)))
#endif

#define vlength(v) ((v)->n)

typedef struct {
  char *arg, *val;
  vari *result;
  INT used; } carg;

typedef struct {
  void (*AddColor)(), (*SetColor)(), (*ClearScreen)(), (*TextDim)(), (*DoText)();
  void (*DrawPoint)(), (*DrawLine)(), (*DrawPatch)(), (*wrapup)();
  INT (*makewin)(), ticklength, defth, deftw;
} device;

typedef struct {
  vari *wk;
  double *coef, *xbar, *f;
  jacobian xtwx; } paramcomp;

typedef struct {
  vari *tw, *L, *iw, *xxev;
  double *x[MXDIM], *y, *w, *base, *c;
  double *coef, *nlx, *t0, *lik, *h, *deg;
  double *sv, dp[LEND], kap[3];
  double sca[MXDIM], fl[2*MXDIM], xl[2*MXDIM];
  INT *ce, *s, *lo, *hi, sty[MXDIM];
  INT *mg, nvm, ncm, vc;
  INT nl, nv, nnl, nce, nk, nn, mi[LENM], ord, deriv[MXDEG+2], nd;
  paramcomp pc;
  varname yname, xname[MXDIM], wname, bname, cname; } lfit;

#define datum(lf,i,j) (lf)->x[i][j]
#define dvari(lf,i)   (lf)->x[i]
#define evpt(lf,i) (&(lf)->xxev->dpr[(i)*(lf)->mi[MDIM]])
#define evptx(lf,i,k) ((lf)->xxev->dpr[(i)*(lf)->mi[MDIM]+(k)])

typedef struct {
  vari *data[MXDIM], *fit, *se;
  INT d, wh, gr;
} pplot;

typedef struct {
  char cmd;
  double x, *v, (*f)();
  INT m, nx[3];
  vari *vv; } arstruct;

typedef struct {
  vari *x, *y, *z;
  char type;
  INT id, t, n, nx, ny, pch; } plxyz;

typedef struct {
  double theta, phi, xl[2], yl[2], zl[2], sl[10];
  INT id, ty, nsl;
  char main[50], xlab[50], ylab[50], zlab[50];
  vari *track, *xyzs; } plots;

#define PLNONE 0
#define PLDATA 1
#define PLFIT  2
#define PLTRK  4

struct lfcol {
  char name[10];
  INT n, r, g, b;
};