BioInt
1.02.00
BioInt: An integrative biological object-oriented application framework and interpreter
|
00001 /**************************************************************************** 00002 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 00003 The BioBhasha : A Programming Language for Biologist 00004 Version 1.0 (19th December 2001) 00005 Dr. Prasad, B.V.L.S. 00006 Version 1.1 (23th January 2003) 00007 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 00008 *****************************************************************************/ 00009 #ifndef BIOSTATISTICS_H 00010 #define BIOSTATISTICS_H 00011 00012 #include <vector> 00013 #include <numeric> 00014 #include <algorithm> 00015 #include <cmath> 00016 00017 using namespace std; 00018 00019 class BioStatistics 00020 { 00021 00022 public: 00023 00024 static float getMedian(const vector<float >&x ); 00025 static double getMedian(const vector<double >&x ); 00026 static float getMedian(const vector<int >&x ); 00027 static float getMedian(const vector<long >&x ); 00028 00029 static long getTotal(const vector<long>&); 00030 static long getTotal(const vector<int>&); 00031 static float getTotal(const vector<float>&); 00032 static double getTotal(const vector<double>&); 00033 00034 static long getMaximum(const vector<long>&); 00035 static long getMaximum(const vector<int>&); 00036 static float getMaximum(const vector<float>&); 00037 static double getMaximum(const vector<double>&); 00038 00039 static long getMinimum(const vector<long>&); 00040 static long getMinimum(const vector<int>&); 00041 static float getMinimum(const vector<float>&); 00042 static double getMinimum(const vector<double>&); 00043 00044 static float getMean(const vector<long>&); 00045 static float getMean(const vector<int>&); 00046 static float getMean(const vector<float>&); 00047 static double getMean(const vector<double>&); 00048 00049 static float getStandardDeviation(const vector<long>& ); 00050 static float getStandardDeviation(const vector<int>& ); 00051 static float getStandardDeviation(const vector<float>& ); 00052 static double getStandardDeviation(const vector<double>& ); 00053 00054 static float getVariance(const vector<long>& ); 00055 static float getVariance(const vector<int>& ); 00056 static float getVariance(const vector<float>& ); 00057 static double getVariance(const vector<double>& ); 00058 00059 static vector<float> getNormalizedDataSet(const vector<long>& ); 00060 static vector<float> getNormalizedDataSet(const vector<float>&); 00061 static vector<float> getNormalizedDataSet(const vector<int>&); 00062 static vector<double> getNormalizedDataSet(const vector<double>&); 00063 00064 static float getRMSD(const vector<long>& , const vector<long>& ); 00065 static float getRMSD(const vector<int>& , const vector<int>& ); 00066 static float getRMSD(const vector<float>& , const vector<float>& ); 00067 static double getRMSD(const vector<double>& , const vector<double>& ); 00068 00069 static float getCorrelationCoefficient(const vector<long>& , const vector<long>& ); 00070 static float getCorrelationCoefficient(const vector<int>& , const vector<int>& ); 00071 static float getCorrelationCoefficient(const vector<float>& , const vector<float>& ); 00072 static double getCorrelationCoefficient(const vector<double>& , const vector<double>& ); 00073 }; 00074 00075 00076 #endif