#include <Histo2d.h>
|
| Histo2d () |
|
| Histo2d (int nx, float minx, float maxx, int ny, float miny, float maxy) |
|
| Histo2d (const Histo2d &other) |
|
void | fill (float x, float y, float weight=1.) |
|
double | maxBin (double &x, double &y) const |
|
void | binWidth (double &Hdx, double &Hdy) const |
|
double | binContent (double x, double y) const |
|
void | zeroBin (double x, double y) |
|
| ~Histo2d () |
|
Definition at line 31 of file Histo2d.h.
◆ Histo2d() [1/3]
lsst::jointcal::Histo2d::Histo2d |
( |
| ) |
|
|
inline |
◆ Histo2d() [2/3]
lsst::jointcal::Histo2d::Histo2d |
( |
int |
nx, |
|
|
float |
minx, |
|
|
float |
maxx, |
|
|
int |
ny, |
|
|
float |
miny, |
|
|
float |
maxy |
|
) |
| |
Definition at line 39 of file Histo2d.cc.
45 scalex = nx / (mmaxx - mminx);
47 LOGL_WARN(_log,
"Histo2d: minx = maxx requested");
51 scaley = ny / (mmaxy - mminy);
53 LOGL_WARN(_log,
"Histo2d: maxy = miny requested");
56 data.reset(
new float[nx * ny]);
57 memset(
data.get(), 0, nx * ny *
sizeof(
float));
◆ Histo2d() [3/3]
lsst::jointcal::Histo2d::Histo2d |
( |
const Histo2d & |
other | ) |
|
◆ ~Histo2d()
lsst::jointcal::Histo2d::~Histo2d |
( |
| ) |
|
|
inline |
◆ binContent()
double lsst::jointcal::Histo2d::binContent |
( |
double |
x, |
|
|
double |
y |
|
) |
| const |
Definition at line 101 of file Histo2d.cc.
103 if (indices(
x,
y, ix, iy))
return data[iy + ny * ix];
104 LOGL_WARN(_log,
"Histo2D::binContent outside limits requested");
◆ binWidth()
void lsst::jointcal::Histo2d::binWidth |
( |
double & |
Hdx, |
|
|
double & |
Hdy |
|
) |
| const |
|
inline |
◆ fill()
void lsst::jointcal::Histo2d::fill |
( |
float |
x, |
|
|
float |
y, |
|
|
float |
weight = 1. |
|
) |
| |
◆ maxBin()
double lsst::jointcal::Histo2d::maxBin |
( |
double & |
x, |
|
|
double & |
y |
|
) |
| const |
Definition at line 78 of file Histo2d.cc.
83 for (p =
data.get(), pend = p + nx * ny; pend - p; p++) {
86 imax = p - (
data.get());
90 int iy = imax - ix * ny;
91 x = minx + ((float)ix + 0.5) / scalex;
92 y = miny + ((float)iy + 0.5) / scaley;
◆ zeroBin()
void lsst::jointcal::Histo2d::zeroBin |
( |
double |
x, |
|
|
double |
y |
|
) |
| |
Definition at line 96 of file Histo2d.cc.
98 if (indices(
x,
y, ix, iy))
data[iy + ny * ix] = 0;
The documentation for this class was generated from the following files:
- /j/snowflake/release/lsstsw/stack/1a1d771/Linux64/jointcal/20.0.0/include/lsst/jointcal/Histo2d.h
- /j/snowflake/release/lsstsw/stack/1a1d771/Linux64/jointcal/20.0.0/src/Histo2d.cc