HstStats

HstStats — An object to compute statistics of one and/or two quantities.

Synopsis


#include <gtk-hst/stats.h>


            HstStats;
            HstStatsClass;
HstStats*   hst_stats_new                   ();
gdouble     hst_stats_get_nc                (HstStats *self);
gdouble     hst_stats_get_mean              (HstStats *self,
                                             int w);
gdouble     hst_stats_get_rms               (HstStats *self,
                                             int w);
gdouble     hst_stats_get_stdev             (HstStats *self,
                                             int w);
gdouble     hst_stats_get_min               (HstStats *self,
                                             int w);
gdouble     hst_stats_get_max               (HstStats *self,
                                             int w);
gdouble     hst_stats_get_correlation       (HstStats *self);
void        hst_stats_add                   (HstStats *self,
                                             double x,
                                             double y,
                                             double w);
void        hst_stats_reset                 (HstStats *self);


Object Hierarchy


  GObject
   +----HstStats

Properties


  "corr"                 gdouble               : Read
  "mean-x"               gdouble               : Read
  "mean-y"               gdouble               : Read
  "nc"                   gdouble               : Read
  "rms-x"                gdouble               : Read
  "rms-y"                gdouble               : Read
  "stdev-x"              gdouble               : Read
  "stdev-y"              gdouble               : Read
  "xmax"                 gdouble               : Read
  "xmin"                 gdouble               : Read
  "ymax"                 gdouble               : Read
  "ymin"                 gdouble               : Read

Description

Details

HstStats

typedef struct _HstStats HstStats;


HstStatsClass

typedef struct {
      GObjectClass __parent__;
} HstStatsClass;


hst_stats_new ()

HstStats*   hst_stats_new                   ();

This is a convinience function to a create a HstStats object.

Returns : a HstStats object.

hst_stats_get_nc ()

gdouble     hst_stats_get_nc                (HstStats *self);

self : a HstStats object
Returns : the number of entries

hst_stats_get_mean ()

gdouble     hst_stats_get_mean              (HstStats *self,
                                             int w);

self : a HstStats object
w : specifies which of the 2 variables is to be considered. (=0) is X and (=1) is Y.
Returns : the mean value of the selected variable

hst_stats_get_rms ()

gdouble     hst_stats_get_rms               (HstStats *self,
                                             int w);

self : a HstStats object
w : specifies which of the 2 variables is to be considered. (=0) is X and (=1) is Y.
Returns : the RMS of the selected variable

hst_stats_get_stdev ()

gdouble     hst_stats_get_stdev             (HstStats *self,
                                             int w);

self : a HstStats object
w : specifies which of the 2 variables is to be considered. (=0) is X and (=1) is Y.
Returns : the standard deviation of the selected variable

hst_stats_get_min ()

gdouble     hst_stats_get_min               (HstStats *self,
                                             int w);

self : a HstStats object
w : specifies which of the 2 variables is to be considered. (=0) is X and (=1) is Y.
Returns : the minimum value of the selected variable

hst_stats_get_max ()

gdouble     hst_stats_get_max               (HstStats *self,
                                             int w);

self : a HstStats object
w : specifies which of the 2 variables is to be considered. (=0) is X and (=1) is Y.
Returns : the maximum value of the selected variable

hst_stats_get_correlation ()

gdouble     hst_stats_get_correlation       (HstStats *self);

self : a HstStats object
Returns : the correlation between X and Y

hst_stats_add ()

void        hst_stats_add                   (HstStats *self,
                                             double x,
                                             double y,
                                             double w);

Adds a new point with a given point

self : a HstStats object
x : value of X
y : value of Y
w : the weight of this point

hst_stats_reset ()

void        hst_stats_reset                 (HstStats *self);

Resets the statistics.

self : a HstStats object

Property Details

The "corr" property

  "corr"                 gdouble               : Read

X and Y correlation.

Default value: 0


The "mean-x" property

  "mean-x"               gdouble               : Read

Mean value of X.

Default value: 0


The "mean-y" property

  "mean-y"               gdouble               : Read

Mean value of Y.

Default value: 0


The "nc" property

  "nc"                   gdouble               : Read

Number of entries.

Default value: 0


The "rms-x" property

  "rms-x"                gdouble               : Read

RMS of X.

Default value: 0


The "rms-y" property

  "rms-y"                gdouble               : Read

RMS of Y.

Default value: 0


The "stdev-x" property

  "stdev-x"              gdouble               : Read

Standard deviation of X.

Default value: 0


The "stdev-y" property

  "stdev-y"              gdouble               : Read

Standard deviation of Y.

Default value: 0


The "xmax" property

  "xmax"                 gdouble               : Read

X maximum value.

Default value: 0


The "xmin" property

  "xmin"                 gdouble               : Read

X minimum value.

Default value: 0


The "ymax" property

  "ymax"                 gdouble               : Read

Y maximum value.

Default value: 0


The "ymin" property

  "ymin"                 gdouble               : Read

Y minimum value.

Default value: 0