Rogue Wave banner
Previous fileTop of DocumentContentsIndexNext file

Histogram


HistogramRWMathVec<int>

Data Type and Member Function Indexes
(exclusive of constructors and destructors)

Synopsis

#include <rw/histo.h>
#include <rw/math/mathvec.h>
RWMathVec<double> v;
unsigned n;
Histogram H(n, v);

Description

The class Histogram constructs and maintains a histogram of input data. The count is stored as a public RWMathVec<int> base class. It can be used anywhere an RWMathVec<int> can be used.

Public Constructors

Histogram();
Histogram(unsigned nbins, const RWMathVec<double>& v);
Histogram(unsigned nbins, double min, double max);
Histogram(const RWMathVec<double>& b);
Histogram(const Histogram& h);

Public Member Functions

void
addCount(double a);
void
addCount(const RWMathVec<double>& v);
RWMathVec<double>
binBoundaries() const;
unsigned
bins() const;
unsigned
larger() const;
Histogram&
resetCounts();
unsigned
smaller() const;
unsigned
totalCount() const;

Public Member Operators

Histogram&  operator=(const Histogram& h) 
ostream&    operator<<(ostream& s, const Histogram& h);


Previous fileTop of DocumentContentsIndexNext file

©Copyright 1999, Rogue Wave Software, Inc.
Send mail to report errors or comment on the documentation.