Isis Developer Reference
|
This is the QwtRasterData for a scatter plot. More...
#include <ScatterPlotData.h>
Public Member Functions | |
ScatterPlotData (Cube *xCube, int xCubeBand, int xBinCount, Cube *yCube, int yCubeBand, int yBinCount, QwtInterval sampleRange, QwtInterval lineRange) | |
ScatterPlotDataConstructor. | |
ScatterPlotData (const ScatterPlotData &other) | |
This is an optimized copy constructor. | |
~ScatterPlotData () | |
Destructor. | |
virtual QwtRasterData * | copy () const |
Returns a copy of the ScatterPlotData object. | |
virtual double | value (double x, double y) const |
This gets called every time the scatter plot is re-drawn. | |
double | xCubeMin () const |
Return the min DN value for the x-axis cube's data range. | |
double | xCubeMax () const |
Return the max DN value for the y-axis cube's data range. | |
double | yCubeMin () const |
Return the min DN value for the y-axis cube's data range. | |
double | yCubeMax () const |
Return the max DN value for the y-axis cube's data range. | |
void | swap (ScatterPlotData &other) |
This is part of the copy-and-swap paradigm. | |
QPair< double, double > | binXY (int binIndex) const |
Get the center X/Y Dn values for the bin at index. | |
int | binCount (int binIndex) const |
Get the count (number of values) which fall into the bin at index. | |
int | numberOfBins () const |
Get the total number of bins (bin count in x * bin count in y). | |
QVector< double > | discreteXValues () const |
Get a list of all of the x-bin center values for this scatter plot. | |
void | alarm (double x, double y) |
Alarm the bin (highlight it) at the given x/y DN value. | |
void | clearAlarms () |
Forget all alarmed bins (viewport->plot). | |
QRectF | pixelHint (const QRectF &area) const |
This is a hint given to qwt for how to render a pixel in the spectrogram. | |
ScatterPlotData & | operator= (const ScatterPlotData &other) |
Take the data from other and copy it into this. | |
This is the QwtRasterData for a scatter plot.
This gives Qwt values to put in each bin for a spectrogram, effectively making the scatter plot.
Isis::ScatterPlotData::ScatterPlotData | ( | Cube * | xCube, |
int | xCubeBand, | ||
int | xBinCount, | ||
Cube * | yCube, | ||
int | yCubeBand, | ||
int | yBinCount, | ||
QwtInterval | sampleRange, | ||
QwtInterval | lineRange ) |
ScatterPlotDataConstructor.
xCube | The x-axis cube |
xCubeBand | The x-axis cube's band to get DN values from |
xBinCount | The resolution of the x-axis |
yCube | The y-axis cube |
yCubeBand | The y-axis cube's band to get DN values from |
yBinCount | The resolution of the y-axis |
sampleRange | The sample range to gather the histogram from, this is the same for the x cube and y cube. |
lineRange | The line range to gather the histogram from, this is the same for the x cube and y cube. |
References Isis::IsSpecial(), and value().
Referenced by copy().
Isis::ScatterPlotData::ScatterPlotData | ( | const ScatterPlotData & | other | ) |
This is an optimized copy constructor.
Copies are not zero-time, but they are pretty quick.
other | The ScatterPlotData to copy. |
Isis::ScatterPlotData::~ScatterPlotData | ( | ) |
Destructor.
void Isis::ScatterPlotData::alarm | ( | double | x, |
double | y ) |
Alarm the bin (highlight it) at the given x/y DN value.
This is for viewport->plot alarming.
x | The x-dn value of the bin to alarm |
y | The y-dn value of the bin to alarm |
int Isis::ScatterPlotData::binCount | ( | int | binIndex | ) | const |
Get the count (number of values) which fall into the bin at index.
binIndex | The bin we're getting the data from |
References binCount().
Referenced by binCount(), and value().
QPair< double, double > Isis::ScatterPlotData::binXY | ( | int | index | ) | const |
Get the center X/Y Dn values for the bin at index.
index | The bin to get the center X/Y DN Values for |
References _FILEINFO_, numberOfBins(), and Isis::IException::Programmer.
void Isis::ScatterPlotData::clearAlarms | ( | ) |
Forget all alarmed bins (viewport->plot).
Referenced by Isis::ScatterPlotWindow::setMousePosition().
|
virtual |
Returns a copy of the ScatterPlotData object.
References ScatterPlotData().
QVector< double > Isis::ScatterPlotData::discreteXValues | ( | ) | const |
Get a list of all of the x-bin center values for this scatter plot.
int Isis::ScatterPlotData::numberOfBins | ( | ) | const |
Get the total number of bins (bin count in x * bin count in y).
Referenced by binXY().
ScatterPlotData & Isis::ScatterPlotData::operator= | ( | const ScatterPlotData & | other | ) |
Take the data from other and copy it into this.
This uses the copy-and-swap paradigm for exception safety.
other | The scatter plot data which needs copied to this |
References swap().
QRectF Isis::ScatterPlotData::pixelHint | ( | const QRectF & | area | ) | const |
This is a hint given to qwt for how to render a pixel in the spectrogram.
area | This is ignored |
void Isis::ScatterPlotData::swap | ( | ScatterPlotData & | other | ) |
This is part of the copy-and-swap paradigm.
Swap member data with other.
other | The class to trade member data with |
Referenced by operator=().
|
virtual |
This gets called every time the scatter plot is re-drawn.
This returns the counts for each DN (x), DN (y), or if the bin is alarmed this returns the max count.
x | The X-Dn value |
y | The Y-Dn value |
References binCount(), and value().
Referenced by ScatterPlotData(), and value().
double Isis::ScatterPlotData::xCubeMax | ( | ) | const |
Return the max DN value for the y-axis cube's data range.
Referenced by Isis::ScatterPlotWindow::ScatterPlotWindow().
double Isis::ScatterPlotData::xCubeMin | ( | ) | const |
Return the min DN value for the x-axis cube's data range.
Referenced by Isis::ScatterPlotWindow::ScatterPlotWindow().
double Isis::ScatterPlotData::yCubeMax | ( | ) | const |
Return the max DN value for the y-axis cube's data range.
Referenced by Isis::ScatterPlotWindow::ScatterPlotWindow().
double Isis::ScatterPlotData::yCubeMin | ( | ) | const |
Return the min DN value for the y-axis cube's data range.
Referenced by Isis::ScatterPlotWindow::ScatterPlotWindow().