SciDAVis
1.D4
|
#include <PlotCurve.h>
Public Member Functions | |
void | addErrorBars (DataCurve *c) |
Adds a single error bars curve to the list of attached error bars. | |
void | clearErrorBars () |
Clears the list of attached error bars. | |
QList< QVector< double > > | convertData (const QList< Column * > &cols, const QList< int > &axes) const |
DataCurve (Table *t, const QString &xColName, const QString &name, int startRow=0, int endRow=-1) | |
int | endRow () |
QList< DataCurve * > | errorBarsList () |
The list of attached error bars. | |
bool | hasSelectedLabels () |
bool | isFullRange () |
virtual bool | loadData () |
virtual QString | plotAssociation () |
A list of data sources for this curve. | |
void | remove () |
void | removeErrorBars (DataCurve *c) |
Remove a single error bars curve from the list of attached error bars. | |
void | setFullRange () |
void | setLabelsSelected (bool on=true) |
void | setRowRange (int startRow, int endRow) |
void | setVisible (bool on) |
void | setXColumnName (const QString &name) |
void | setYColumnName (const QString &name) |
int | startRow () |
Table * | table () |
int | tableRow (int point) |
Returns the row index in the data source table corresponding to the data point index. | |
virtual void | updateColumnNames (const QString &oldName, const QString &newName, bool updateTableName) |
virtual bool | updateData (Table *t, const QString &colName) |
QString | xColumnName () |
QString | yColumnName () |
Public Member Functions inherited from PlotCurve | |
QwtDoubleRect | boundingRect () const |
PlotCurve (const QString &name=QString::null) | |
void | setType (int t) |
int | type () const |
Protected Attributes | |
int | d_end_row |
Last row of #d_tabel to be plotted, provided all relevant columns have valid entries. | |
QList< DataCurve * > | d_error_bars |
List of the error bar curves associated to this curve. | |
int | d_start_row |
First row of #d_tabel to be plotted, provided all relevant columns have valid entries. | |
Table * | d_table |
The data source table. | |
QString | d_x_column |
The name of the column used for abscissae values. | |
Protected Attributes inherited from PlotCurve | |
int | d_type |
Private Member Functions | |
bool | validCurveType () |
Private Attributes | |
QVector< int > | d_index_to_row |
Mapping of curve indices to row indices in d_table. |
DataCurve::DataCurve | ( | Table * | t, |
const QString & | xColName, | ||
const QString & | name, | ||
int | startRow = 0 , |
||
int | endRow = -1 |
||
) |
References d_end_row, and Table::numRows().
|
inline |
Adds a single error bars curve to the list of attached error bars.
References d_error_bars.
Referenced by QwtErrorPlotCurve::setMasterCurve().
void DataCurve::clearErrorBars | ( | ) |
Clears the list of attached error bars.
References d_error_bars, and remove().
Referenced by Graph::setCurveType().
QList< QVector< double > > DataCurve::convertData | ( | const QList< Column * > & | cols, |
const QList< int > & | axes | ||
) | const |
References Graph::axesType(), Graph::axisFormatInfo(), Column::columnMode(), d_end_row, d_index_to_row, d_start_row, Table::Date, Graph::Date, Column::dateAt(), Table::DateTime, Graph::DateTime, Column::dateTimeAt(), Column::isInvalid(), Column::outputFilter(), Column::rowCount(), Graph::setLabelsDateTimeFormat(), Graph::setLabelsTextFormat(), Table::Text, Table::Time, Graph::Time, and Column::timeAt().
Referenced by loadData(), and QwtErrorPlotCurve::loadData().
|
inline |
|
inline |
The list of attached error bars.
References d_error_bars.
Referenced by Fit::setYErrorSource(), and ApplicationWindow::showCurveContextMenu().
bool DataCurve::hasSelectedLabels | ( | ) |
bool DataCurve::isFullRange | ( | ) |
References d_end_row, d_start_row, d_table, and Table::numRows().
Referenced by ApplicationWindow::showCurveContextMenu().
|
virtual |
Reimplemented in QwtErrorPlotCurve, VectorCurve, BoxCurve, QwtPieCurve, and QwtHistogram.
References Table::column(), convertData(), d_error_bars, d_table, PlotCurve::d_type, d_x_column, and Graph::HorizontalBars.
Referenced by AssociationsDialog::changePlotAssociation(), Graph::insertCurve(), Graph::setCurveType(), setFullRange(), setRowRange(), and updateData().
|
virtual |
A list of data sources for this curve.
Elements must be in either of the following forms:
Column ids are of the form '<name of table> "_" <name of column>'.
Reimplemented in VectorCurve, and QwtErrorPlotCurve.
References d_x_column.
Referenced by AssociationsDialog::changePlotAssociation(), Graph::masterCurve(), and Graph::updateCurveNames().
void DataCurve::remove | ( | ) |
References Graph::removeCurve().
Referenced by AssociationsDialog::changePlotAssociation(), and clearErrorBars().
void DataCurve::removeErrorBars | ( | DataCurve * | c | ) |
Remove a single error bars curve from the list of attached error bars.
References d_error_bars.
Referenced by QwtErrorPlotCurve::detachFromMasterCurve().
void DataCurve::setFullRange | ( | ) |
References d_end_row, d_error_bars, d_start_row, d_table, loadData(), and Table::numRows().
Referenced by Graph::setCurveFullRange().
void DataCurve::setLabelsSelected | ( | bool | on = true | ) |
void DataCurve::setRowRange | ( | int | startRow, |
int | endRow | ||
) |
References d_end_row, d_error_bars, d_start_row, endRow(), loadData(), and startRow().
Referenced by CurveRangeDialog::accept().
void DataCurve::setVisible | ( | bool | on | ) |
References d_error_bars, and setVisible().
Referenced by Graph::plotPie(), and setVisible().
|
inline |
References d_x_column.
Referenced by AssociationsDialog::changePlotAssociation().
|
inline |
|
inline |
|
inline |
References d_table.
Referenced by Graph::copy(), QwtErrorPlotCurve::loadData(), CurveRangeDialog::setCurveToModify(), Graph::setCurveType(), and Graph::updateCurvesData().
int DataCurve::tableRow | ( | int | point | ) |
Returns the row index in the data source table corresponding to the data point index.
References d_index_to_row.
Referenced by TranslateCurveTool::selectDestination().
|
virtual |
|
virtual |
Reimplemented in QwtErrorPlotCurve, and VectorCurve.
References d_table, d_x_column, and loadData().
|
private |
|
inline |
|
inline |
Referenced by Graph::setCurveType(), and Graph::updateCurvesData().
|
protected |
Last row of #d_tabel to be plotted, provided all relevant columns have valid entries.
Referenced by VectorCurve::boundingRect(), convertData(), DataCurve(), endRow(), isFullRange(), QwtHistogram::loadData(), QwtPieCurve::loadData(), BoxCurve::loadData(), VectorCurve::loadData(), setFullRange(), QwtErrorPlotCurve::setMasterCurve(), and setRowRange().
|
protected |
List of the error bar curves associated to this curve.
Referenced by addErrorBars(), clearErrorBars(), errorBarsList(), loadData(), VectorCurve::loadData(), removeErrorBars(), setFullRange(), setRowRange(), and setVisible().
|
mutableprivate |
Mapping of curve indices to row indices in d_table.
Besides d_start_row and d_end_row, this takes into account rows which had invalid entries in one of the relevant columns the last time convertData() was called. Usually, changes in validity should cause the curve to be updated via updateData(); however, subclasses of DataCurve may depend on more columns than X and Y (in particular, this is true of vector curves); so DataCurve cannot (within the current architecture) compute this mapping on demand and has to store it like this.
Referenced by convertData(), and tableRow().
|
protected |
First row of #d_tabel to be plotted, provided all relevant columns have valid entries.
Referenced by VectorCurve::boundingRect(), convertData(), isFullRange(), QwtHistogram::loadData(), QwtPieCurve::loadData(), BoxCurve::loadData(), VectorCurve::loadData(), setFullRange(), QwtErrorPlotCurve::setMasterCurve(), setRowRange(), and startRow().
|
protected |
The data source table.
Referenced by isFullRange(), QwtHistogram::loadData(), QwtPieCurve::loadData(), loadData(), BoxCurve::loadData(), VectorCurve::loadData(), QwtErrorPlotCurve::loadData(), setFullRange(), table(), updateData(), QwtErrorPlotCurve::updateData(), and VectorCurve::updateData().
|
protected |
The name of the column used for abscissae values.
Referenced by loadData(), VectorCurve::loadData(), VectorCurve::plotAssociation(), plotAssociation(), setXColumnName(), VectorCurve::updateColumnNames(), updateColumnNames(), updateData(), VectorCurve::updateData(), and xColumnName().