42 #ifndef _MSNUMPRESS_HPP_
43 #define _MSNUMPRESS_HPP_
51 namespace MSNumpress {
79 const size_t dataSize,
80 unsigned char *result,
90 const std::vector<double> &data,
91 std::vector<unsigned char> &result,
111 const unsigned char *data,
112 const size_t dataSize,
122 const std::vector<unsigned char> &data,
123 std::vector<double> &result);
142 const size_t dataSize,
143 unsigned char *result);
152 const std::vector<double> &data,
153 std::vector<unsigned char> &result);
166 const std::vector<unsigned char> &data,
167 std::vector<double> &result);
176 const unsigned char *data,
177 const size_t dataSize,
206 const size_t dataSize,
207 unsigned char *result,
217 const std::vector<double> &data,
218 std::vector<unsigned char> &result,
230 const unsigned char *data,
231 const size_t dataSize,
241 const std::vector<unsigned char> &data,
242 std::vector<double> &result);
248 #endif // _MSNUMPRESS_HPP_
size_t encodePic(const double *data, const size_t dataSize, unsigned char *result)
Encodes ion counts by simply rounding to the nearest 4 byte integer, and compressing each integer wit...
double optimalSlofFixedPoint(const double *data, size_t dataSize)
double optimalLinearFixedPoint(const double *data, size_t dataSize)
size_t encodeLinear(const double *data, const size_t dataSize, unsigned char *result, double fixedPoint)
Encodes the doubles in data by first using a.
size_t decodeLinear(const unsigned char *data, const size_t dataSize, double *result)
Decodes data encoded by encodeLinear.
void decodePic(const std::vector< unsigned char > &data, std::vector< double > &result)
Decodes data encoded by encodePic.
size_t decodeSlof(const unsigned char *data, const size_t dataSize, double *result)
Decodes data encoded by encodeSlof.
size_t encodeSlof(const double *data, const size_t dataSize, unsigned char *result, double fixedPoint)
Encodes ion counts by taking the natural logarithm, and storing a fixed point representation of this...