ProteoWizard
DatabaseQuery.hpp
Go to the documentation of this file.
1 //
2 // $Id: DatabaseQuery.hpp 1539 2009-11-19 20:12:28Z khoff $
3 //
4 //
5 // Original author: Kate Hoff <katherine.hoff@proteowizard.org>
6 //
7 // Copyright 2009 Center for Applied Molecular Medicine
8 // University of Southern California, Los Angeles, CA
9 //
10 // Licensed under the Apache License, Version 2.0 (the "License");
11 // you may not use this file except in compliance with the License.
12 // You may obtain a copy of the License at
13 //
14 // http://www.apache.org/licenses/LICENSE-2.0
15 //
16 // Unless required by applicable law or agreed to in writing, software
17 // distributed under the License is distributed on an "AS IS" BASIS,
18 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19 // See the License for the specific language governing permissions and
20 // limitations under the License.
21 //
22 
23 ///
24 /// DatabaseQuery.hpp
25 ///
26 
27 #ifndef _DATABASEQUERY_HPP_
28 #define _DATABASEQUERY_HPP_
29 
30 #include "FeatureSequenced.hpp"
33 
34 namespace pwiz{
35 namespace eharmony{
36 
37 using namespace pwiz::data::pepxml;
38 
39 typedef boost::shared_ptr<SpectrumQuery> SpectrumQueryPtr;
40 // Independent of retention time calibration, this struct allows querying of a feature to the database as a whole and is constructed from the database itself
41 
43 {
44  std::vector<MatchPtr> query(FeatureSequencedPtr fs, NormalDistributionSearch nds, double threshold);
45 
46  pair<double,double> calculateSearchRegion(const double& mu1, const double& mu2, const double& sigma1, const double& sigma2, const double& threshold);
47  pair<double,double> calculateNormalSearchRegion(const double& mu1, const double& mu2, double& sigma1, double& sigma2, const double& threshold);
48 
50  DatabaseQuery(const PidfPtr database) : _database(database){}
51 
52 };
53 
54 }
55 }
56 
57 
58 #endif