27 #include "../../common/Translator.h"
28 #include "../../dataaccess/dataset/DataSet.h"
35 #include <boost/lexical_cast.hpp>
42 return TE_TR(
"MIN_VALUE");
45 return TE_TR(
"MAX_VALUE");
54 return TE_TR(
"COUNT");
57 return TE_TR(
"VALID_COUNT");
60 return TE_TR(
"STANDARD_DEVIATION");
63 return TE_TR(
"VARIANCE");
66 return TE_TR(
"SKEWNESS");
69 return TE_TR(
"KURTOSIS");
72 return TE_TR(
"AMPLITUDE");
75 return TE_TR(
"MEDIAN");
78 return TE_TR(
"VAR_COEFF");
93 return TE_TR(
"Minimum value");
96 return TE_TR(
"Maximum value");
102 return TE_TR(
"Sum of values");
105 return TE_TR(
"Total number of values");
108 return TE_TR(
"Total not null values");
111 return TE_TR(
"Standard deviation");
114 return TE_TR(
"Variance");
117 return TE_TR(
"Skewness");
120 return TE_TR(
"Kurtosis");
123 return TE_TR(
"Amplitude");
126 return TE_TR(
"Median");
129 return TE_TR(
"Coefficient variation");
132 return TE_TR(
"Mode");
141 std::vector<std::string> result;
142 std::string value=
"";
148 if (!dataSet->
isNull(propName))
151 result.push_back(value);
160 std::vector<double> result;
172 if (!dataSet->
isNull(propName))
179 numval = (double)dataSet->
getInt64(index);
185 numval = boost::lexical_cast<
double>(dataSet->
getNumeric(index));
186 result.push_back(numval);
virtual boost::int16_t getInt16(std::size_t i) const =0
Method for retrieving a 16-bit integer attribute value (2 bytes long).
virtual boost::int32_t getInt32(std::size_t i) const =0
Method for retrieving a 32-bit integer attribute value (4 bytes long).
virtual boost::int64_t getInt64(std::size_t i) const =0
Method for retrieving a 64-bit integer attribute value (8 bytes long).
TESTATEXPORT std::string GetStatSummaryShortName(const int &e)
Get the statistical parameter short name from its enumerator.
Utility functions for Statistics.
virtual std::string getNumeric(std::size_t i) const =0
Method for retrieving a numeric attribute value.
#define TE_TR(message)
It marks a string in order to get translated.
virtual double getDouble(std::size_t i) const =0
Method for retrieving a double attribute value.
TESTATEXPORT std::vector< double > GetNumericData(te::da::DataSet *dataSet, const std::string propName)
Returns the values of a numeric type property in a vector of values.
virtual bool moveNext()=0
It moves the internal pointer to the next item of the collection.
virtual float getFloat(std::size_t i) const =0
Method for retrieving a float attribute value.
virtual std::string getPropertyName(std::size_t i) const =0
It returns the property name at position pos.
TESTATEXPORT std::vector< std::string > GetStringData(te::da::DataSet *dataSet, const std::string propName)
Returns the values of a string type property in a vector of values.
virtual bool isNull(std::size_t i) const =0
It checks if the attribute value is NULL.
Enumerations related to Vector Processing module.
TESTATEXPORT std::string GetStatSummaryFullName(const int &e)
Get the statistical parameter full name ffrom its enumerator.
virtual std::size_t getNumProperties() const =0
It returns the number of properties that composes an item of the dataset.
A dataset is the unit of information manipulated by the data access module of TerraLib.
virtual std::string getString(std::size_t i) const =0
Method for retrieving a string value attribute.
An exception class for the statistical module.
virtual int getPropertyDataType(std::size_t i) const =0
It returns the underlying data type of the property at position pos.
virtual bool moveFirst()=0
It moves the internal pointer to the first item in the collection.
Configuration flags for the Terrralib Statistic module.