00001 #ifndef __vtkMultiCorrelativeStatisticsAssessFunctor_h 00002 #define __vtkMultiCorrelativeStatisticsAssessFunctor_h 00003 00004 #include "vtkStatisticsAlgorithm.h" 00005 00006 #include <vtkstd/vector> 00007 00008 class vtkDataArray; 00009 class vtkTable; 00010 00011 #define VTK_MULTICORRELATIVE_KEYCOLUMN1 "Column1" 00012 #define VTK_MULTICORRELATIVE_KEYCOLUMN2 "Column2" 00013 #define VTK_MULTICORRELATIVE_ENTRIESCOL "Entries" 00014 #define VTK_MULTICORRELATIVE_AVERAGECOL "Mean" 00015 #define VTK_MULTICORRELATIVE_COLUMNAMES "Column" 00016 00017 class vtkMultiCorrelativeAssessFunctor : public vtkStatisticsAlgorithm::AssessFunctor 00018 { 00019 public: 00020 static vtkMultiCorrelativeAssessFunctor* New(); 00021 00022 vtkMultiCorrelativeAssessFunctor() { } 00023 virtual ~vtkMultiCorrelativeAssessFunctor() { } 00024 virtual bool Initialize( vtkTable* inData, vtkTable* reqModel, bool cholesky = true ); 00025 00026 virtual void operator () ( vtkVariantArray* result, vtkIdType row ); 00027 00028 vtkIdType GetNumberOfColumns() { return static_cast<vtkIdType>( this->Columns.size() ); } 00029 vtkDataArray* GetColumn( vtkIdType colIdx ) { return this->Columns[colIdx]; } 00030 00031 vtkstd::vector<vtkDataArray*> Columns; // Source of data 00032 double* Center; // Offset per column (usu. to re-center the data about the mean) 00033 vtkstd::vector<double> Factor; // Weights per column 00034 //double Normalization; // Scale factor for the volume under a multivariate Gaussian used to normalize the CDF 00035 vtkstd::vector<double> Tuple; // Place to store product of detrended input tuple and Cholesky inverse 00036 vtkstd::vector<double> EmptyTuple; // Used to quickly initialize Tuple for each datum 00037 }; 00038 00039 #endif // __vtkMultiCorrelativeStatisticsAssessFunctor_h