GRASS GIS 7 Programmer's Manual  7.5.svn(2017)-r71793
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
cluster.h
Go to the documentation of this file.
1 #ifndef GRASS_CLUSTER_H
2 #define GRASS_CLUSTER_H
3 
4 #include <grass/gis.h>
5 #include <grass/imagery.h>
6 
7 struct Cluster
8 {
9  int nbands; /* number of bands */
10  int npoints; /* number of points */
11  DCELL **points; /* array of points */
12  int np;
13 
14  double *band_sum; /* sum over each band */
15  double *band_sum2; /* sum of squares over each band */
16 
17  int *class; /* class of each point */
18  int *reclass; /* for removing empty classes */
19  int *count; /* number of points in each class */
20  int *countdiff; /* change in count */
21  double **sum; /* sum over band per class */
22  double **sumdiff; /* change in sum */
23  double **sum2; /* sum of squares per band per class */
24  double **mean; /* initial class means */
25  struct Signature S; /* final signature(s) */
26 
27  int nclasses; /* number of classes */
28  int merge1, merge2;
29  int iteration; /* number of iterations */
30  double percent_stable; /* percentage stable */
31 };
32 
33 #include <grass/defs/cluster.h>
34 
35 #endif
int nbands
Definition: cluster.h:9
double ** sum
Definition: cluster.h:21
double ** mean
Definition: cluster.h:24
double * band_sum
Definition: cluster.h:14
int merge1
Definition: cluster.h:28
int nclasses
Definition: cluster.h:27
double DCELL
Definition: gis.h:581
struct Signature S
Definition: cluster.h:25
Definition: cluster.h:7
int npoints
Definition: cluster.h:10
int * count
Definition: cluster.h:19
double ** sum2
Definition: cluster.h:23
double ** sumdiff
Definition: cluster.h:22
DCELL ** points
Definition: cluster.h:11
int * reclass
Definition: cluster.h:18
int np
Definition: cluster.h:12
int merge2
Definition: cluster.h:28
int iteration
Definition: cluster.h:29
int * countdiff
Definition: cluster.h:20
double * band_sum2
Definition: cluster.h:15
double percent_stable
Definition: cluster.h:30