Anova Class Reference

ANOVA. More...

`#include <Anova.h>`

Inheritance diagram for Anova:

## Public Member Functions

bool | addSample (const QString &colName, int aLevel=1, int bLevel=1)
| Anova (ApplicationWindow *parent, bool twoWay=false, double level=0.05)
virtual QString | logInfo ()
double | mse ()
virtual void | outputResultsTo (Table *)
virtual Table * | resultTable (const QString &name=QString())
| Returns a pointer to the table created to display the results. More...
bool | run ()
| Actually does the job. Should be reimplemented in derived classes. More...
void | setAnovaTwoWayModel (int type)
void | showAnovaTwoWayInteractions (bool show=true)
double | sse ()
double | sst ()
One-Way ANOVA results
double | fStat ()
double | statistic ()
double | pValue ()
double | ssm ()
Two-Way ANOVA results
double | fStatA ()
double | fStatB ()
double | fStatAB ()
double | pValueA ()
double | pValueB ()
double | pValueAB ()
double | ssa ()
double | ssb ()
double | ssab ()
double | msa ()
double | msb ()
double | msab ()
Public Member Functions inherited from StatisticTest
virtual double | lcl (double)
| Lower Confidence Limit. More...
void | setSignificanceLevel (double s)
void | setTail (const Tail &tail)
void | setTestValue (double val)
void | showDescriptiveStatistics (bool show=true)
| StatisticTest (ApplicationWindow *parent, double testValue=0.0, double level=0.05, const QString &sample=QString())
virtual double | ucl (double)
| Upper Confidence Limit. More...
Public Member Functions inherited from Statistics
double * | data ()
| Returns the y values of the input data set. More...
unsigned int | dataSize ()
| Returns the size of the input data set. More...
virtual int | dof ()
| Returns the degrees of freedom. More...
QString | logInfo (bool header=true)
double | mean ()
QString | sampleName ()
bool | setData (const QString &)
void | showResultsLog (bool show=true)
double | standardDeviation ()
double | standardError ()
| Statistics (ApplicationWindow *parent, const QString &name=QString())
double | variance ()
| ~Statistics ()

## Protected Member Functions

void | freeMemory ()
| Frees the memory allocated for the X and Y data sets. More...
QString | levelName (int level, bool b=false)
bool | oneWayANOVA ()
bool | twoWayANOVA ()
Protected Member Functions inherited from Statistics
void | memoryErrorMessage ()

## Protected Attributes

gsl_anova_twoway_types | d_anova_type
tamu_anova_table | d_at
tamu_anova_table_twoway | d_att
QList< Statistics * > | d_data_samples
QList< int > | d_factorA_levels
QList< int > | d_factorB_levels
bool | d_show_interactions
bool | d_two_way
Protected Attributes inherited from StatisticTest
bool | d_descriptive_statistics
double | d_significance_level
int | d_tail
double | d_test_val
Protected Attributes inherited from Statistics
QString | d_col_name
| The name of the source data set. More...
double * | d_data
| y data set to be analysed More...
double | d_mean
unsigned int | d_n
| The size of the data set to be analyzed. More...
bool | d_result_log
| Flag specifying if the results should be displayed in the results log. More...
double | d_sd
double | d_se
Table * | d_table
| A table source of data. More...
double | d_variance

## Additional Inherited Members

Public Types inherited from StatisticTest
enum | Tail { Left = 0, Right = 1, Both = 2 }
enum | TestType { StudentTest = 0, NormalityTest = 1, ChiSquareTest = 2, AnovaTest = 3 }

## Detailed Description

ANOVA.

## Constructor & Destructor Documentation

Anova::Anova | ( | ApplicationWindow * | parent,
|  | bool | twoWay = `false`,
|  | double | level = `0.05`
| ) |  |

## Member Function Documentation

bool Anova::addSample | ( | const QString & | colName,
|  | int | aLevel = `1`,
|  | int | bLevel = `1`
| ) |  |

References d_data_samples, d_factorA_levels, d_factorB_levels, Statistics::d_n, d_two_way, Statistics::dataSize(), Statistics::setData(), and Statistics::Statistics().

void Anova::freeMemory | ( |  | ) |

protected virtual

Frees the memory allocated for the X and Y data sets.

Reimplemented from Statistics.

References d_data_samples, and Statistics::freeMemory().

double Anova::fStat | ( |  | ) |

inline

References d_at.

double Anova::fStatA | ( |  | ) |

inline

References d_att.

double Anova::fStatAB | ( |  | ) |

inline

References d_att.

double Anova::fStatB | ( |  | ) |

inline

References d_att.

QString Anova::levelName | ( | int | level,
|  | bool | b = `false`
| ) |  |

protected

Referenced by logInfo(), and twoWayANOVA().

QString Anova::logInfo | ( |  | ) |

virtual

Reimplemented from StatisticTest.

References d_anova_type, d_at, d_att, d_data_samples, ApplicationWindow::d_decimal_digits, StatisticTest::d_descriptive_statistics, d_factorA_levels, d_factorB_levels, d_show_interactions, StatisticTest::d_significance_level, Statistics::d_table, d_two_way, levelName(), Statistics::logInfo(), and Statistics::sampleName().

double Anova::msa | ( |  | ) |

inline

References d_att.

double Anova::msab | ( |  | ) |

inline

References d_att.

double Anova::msb | ( |  | ) |

inline

References d_att.

double Anova::mse | ( |  | ) |

inline

References d_at, d_att, and d_two_way.

bool Anova::oneWayANOVA | ( |  | ) |

protected

References d_at, Statistics::d_data, d_data_samples, Statistics::d_n, Statistics::data(), Statistics::dataSize(), and Statistics::memoryErrorMessage().

Referenced by run().

void Anova::outputResultsTo | ( | Table * | t | ) |

virtual

Reimplemented from StatisticTest.

References d_at, d_att, d_two_way, Table::numCols(), Table::numRows(), Table::setCell(), Table::setColumnType(), Table::setNumCols(), Table::setNumRows(), Table::setText(), Table::table(), and Table::Text.

double Anova::pValue | ( |  | ) |

inline virtual

Reimplemented from StatisticTest.

References d_at.

double Anova::pValueA | ( |  | ) |

inline

References d_att.

double Anova::pValueAB | ( |  | ) |

inline

References d_att.

double Anova::pValueB | ( |  | ) |

inline

References d_att.

Table * Anova::resultTable | ( | const QString & | name = `QString()` | ) |

virtual

Returns a pointer to the table created to display the results.

Reimplemented from StatisticTest.

References d_at, d_att, d_two_way, ApplicationWindow::newTable(), Table::numCols(), Table::setCell(), Table::setColumnType(), Table::setHeader(), Table::setText(), MdiSubWindow::setWindowLabel(), Table::table(), and Table::Text.

bool Anova::run | ( |  | ) |

virtual

Actually does the job. Should be reimplemented in derived classes.

Reimplemented from Statistics.

References d_data_samples, Statistics::d_n, d_two_way, oneWayANOVA(), and twoWayANOVA().

void Anova::setAnovaTwoWayModel | ( | int | type | ) |

inline

References d_anova_type.

void Anova::showAnovaTwoWayInteractions | ( | bool | show = `true` | ) |

inline

References d_show_interactions.

double Anova::ssa | ( |  | ) |

inline

References d_att.

double Anova::ssab | ( |  | ) |

inline

References d_att.

double Anova::ssb | ( |  | ) |

inline

References d_att.

double Anova::sse | ( |  | ) |

inline

References d_at, d_att, and d_two_way.

double Anova::ssm | ( |  | ) |

inline

References d_at.

double Anova::sst | ( |  | ) |

inline

References d_at, d_att, and d_two_way.

double Anova::statistic | ( |  | ) |

inline virtual

Reimplemented from StatisticTest.

References d_at.

bool Anova::twoWayANOVA | ( |  | ) |

protected

References d_anova_type, d_att, Statistics::d_data, d_data_samples, d_factorA_levels, d_factorB_levels, Statistics::d_n, Statistics::data(), Statistics::dataSize(), levelName(), and Statistics::memoryErrorMessage().

Referenced by run().

## Member Data Documentation

gsl_anova_twoway_types Anova::d_anova_type

protected

Referenced by logInfo(), setAnovaTwoWayModel(), and twoWayANOVA().

tamu_anova_table Anova::d_at

protected

Referenced by fStat(), logInfo(), mse(), oneWayANOVA(), outputResultsTo(), pValue(), resultTable(), sse(), ssm(), sst(), and statistic().

tamu_anova_table_twoway Anova::d_att

protected

Referenced by fStatA(), fStatAB(), fStatB(), logInfo(), msa(), msab(), msb(), mse(), outputResultsTo(), pValueA(), pValueAB(), pValueB(), resultTable(), ssa(), ssab(), ssb(), sse(), sst(), and twoWayANOVA().

QList<Statistics *> Anova::d_data_samples

protected

Referenced by addSample(), freeMemory(), logInfo(), oneWayANOVA(), run(), and twoWayANOVA().

QList<int> Anova::d_factorA_levels

protected

Referenced by addSample(), logInfo(), and twoWayANOVA().

QList<int> Anova::d_factorB_levels

protected

Referenced by addSample(), logInfo(), and twoWayANOVA().

bool Anova::d_show_interactions

protected

Referenced by logInfo(), and showAnovaTwoWayInteractions().

bool Anova::d_two_way

protected

Referenced by addSample(), logInfo(), mse(), outputResultsTo(), resultTable(), run(), sse(), and sst().

The documentation for this class was generated from the following files:

- qtiplot/src/analysis/Anova.h
- qtiplot/src/analysis/Anova.cpp