14 #include "msdevstudio/MSconfig.h"
33 #ifdef ITERATOR_MEMBER_DEFECT
38 using std::max_element;
40 using std::min_element;
98 unsigned int index = 0;
99 if ( axis ==
Axes::Y ) index = 1;
100 if ( axis ==
Axes::Z ) index = 2;
112 unsigned int index = 0;
113 if ( axis ==
Axes::Y ) index = 1;
114 if ( axis ==
Axes::Z ) index = 2;
140 double xe = xr.
length() * 0.01;
141 double ye = yr.
length() * 0.01;
146 unsigned int size = xs.size();
147 for (
unsigned int i = 0; i <
size; i++ ) {
148 if ( abs ( x - xs[i] ) < xe &&
149 abs ( y - ys[i] ) < ye ) retval = zs[i];
168 unsigned int columns = 3;
170 vector < string > labels;
171 labels.push_back (
m_ntuple -> getLabelAt ( ix ) );
172 labels.push_back (
m_ntuple -> getLabelAt ( iy ) );
173 labels.push_back (
m_ntuple -> getLabelAt ( iz ) );
174 ntuple -> setLabels ( labels );
188 ntuple -> reserve ( size );
189 vector < double > row ( 3 );
195 for (
unsigned int i = 0; i <
size; i++ ) {
197 ( in_range ==
true &&
inRange ( i ) ==
false ) )
continue;
203 ntuple -> addRow ( row );
virtual void addPointReps()
Function to add the acceptable point reps.
std::vector< std::string > m_pointreps
Vector of acceptable PointReps.
AxisModelBase * m_x_axis
The AxisModel along the X axis.
An NTupleProjector is a projector that projects data from an DataSource object.
virtual DataSource * createNTuple() const
Creates an NTuple representation of the projected values.
std::vector< std::string > m_binding_options
The list of binding options for the Projector.
virtual Range valueRange() const
Finds the range of the projected values.
ProjectorBase * clone()
The clone function returns an object of its own kind which is a copy of this object at this moment...
virtual double getPosOn(hippodraw::Axes::Type axis) const
Returns the minimum positive value of the data on a specified axis.
virtual void fillProjectedValues(DataSource *ntuple, bool in_range=false) const
bool acceptRow(unsigned int i, const CutList_t &cut_list) const
For row i of the column in the DataSource, returns true if all the cuts accept the row...
double length() const
Returns the length of the range object.
hippodraw::AxisModelBase class interface
AxisModelBase * m_y_axis
The AxisModel along the Y axis.
double getPos(int column) const
Returns the minimum positive value on the specified column.
unsigned int m_min_bindings
The minimum number of columns that must be bound.
virtual Range dataRangeOn(hippodraw::Axes::Type) const
Returns the range of the data on the specified axis.
hippodraw::DataPointTuple namespace interface
Map3Projector()
This default constructor binds to the first three columns.
virtual void setDirty(bool value=true)
Sets the dirty flag to value.
A DataSource class implemented with std::vector to store the column data. ...
virtual double getZValue(double x, double y) const
Get the z value at the specified point (x,y).
virtual void prepareValues()
Informs the projector to prepare its projected values for plotting.
intp size(numeric::array arr)
A derived class of NTupleProjector that maps 3 DataSource columns to a 3-dimensional projection...
hippodraw::NTuple class interface.
virtual const std::string & getLabelAt(unsigned int index) const
Returns the label for the column at index index.
Base class for DataSource.
virtual void changedNTuple()
This function is called when the ntuple has been changed to a new one.
DataSource * m_proj_values
The NTuple representing the result of the projection.
hippodraw::Map3Projector class interface
const Range & getRange(bool scaled) const
Returns the range represented by this AxisModel.
unsigned int columns() const
Returns the number of columns or data arrays available from this DataSource.
std::vector< unsigned int > m_columns
A vector containing indexes to the columns of the DataSource.
CutList_t m_cut_list
A list of cuts that filter the projection.
const std::string & getZLabel() const
Returns the label (title) of the z axis.
A namespace to set the standard for indexing into 3 dimension data point tuple.
const DataSource * m_ntuple
The pointer to the data source being projected.
virtual bool inRange(int row) const
Checks if the entries in a given row are within the range of the axis model.
Range dataRange(int column) const
Returns the range of data on the specified column.
Expresses a range of values.
A namespace to set the standard for indexing into 2 dimension data point tuple.
The base class for the Projector hierarchy.