DatabaseQueryTest.cpp File Reference
#include "DatabaseQuery.hpp"
#include "pwiz/utility/misc/unit.hpp"

Go to the source code of this file.


void test ()
int main ()

Function Documentation

void test ( )

Definition at line 34 of file DatabaseQueryTest.cpp.

References pwiz::eharmony::DatabaseQuery::calculateSearchRegion(), and unit_assert_equal.

double mu1 = 1;
double mu2 = 2;
double sigma1 = 2;
double sigma2 = 4;
double threshold = 0.7;
// Given a normal distribution fit to mz and rt differences, calculate the folded normal distribution correspoding to the parameters of the original distribution. Using this distribution and an explicit approximation to the error function, calculate the region of mz x rt space that it is necessary to search in order to find all the matches that would score higher than the given threshold.
pair<double,double> radii = dbQuery.calculateSearchRegion(mu1, mu2, sigma1, sigma2, threshold);
unit_assert_equal(radii.first, 10.047046209584696, .000001);
int main ( )

Definition at line 51 of file DatabaseQueryTest.cpp.

References test().

return 0;