ITK  4.6.0
Insight Segmentation and Registration Toolkit
itkBioGenome.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __itkBioGenome_h
19 #define __itkBioGenome_h
20 
21 
22 #if defined( _WIN32 )
23 #include "itkWindows.h"
24 #endif
25 #include "itkMacro.h"
26 
27 #include <map>
28 #include <string>
29 #include <cmath>
30 
31 namespace itk
32 {
33 namespace bio
34 {
44 class Genome
45 {
46 public:
47  typedef std::string GeneIdType;
48  typedef std::map< GeneIdType, double > MapType;
49 
50 public:
51  Genome();
52  virtual ~Genome();
53 
54  void Copy(const Genome & genome);
55 
56  void InsertGene(const GeneIdType & geneId);
57 
58  void KnockOutGene(const GeneIdType & geneId);
59 
60  double GetExpressionLevel(const GeneIdType & geneId);
61 
62  void SetExpressionLevel(const GeneIdType & geneId, double level);
63 
66  static double Sigmoide(double threshold, double slant, double value)
67  {
68  return std::atan( ( value - threshold ) / slant ) / 3.1416 + 0.5001;
69  }
70 
71 private:
73 };
74 } // end namespace bio
75 } // end namespace itk
76 
77 #endif
static double Sigmoide(double threshold, double slant, double value)
Definition: itkBioGenome.h:66
std::map< GeneIdType, double > MapType
Definition: itkBioGenome.h:48
virtual ~Genome()
This class implements the abstraction of a biological genome.
Definition: itkBioGenome.h:44
void SetExpressionLevel(const GeneIdType &geneId, double level)
double GetExpressionLevel(const GeneIdType &geneId)
void InsertGene(const GeneIdType &geneId)
std::string GeneIdType
Definition: itkBioGenome.h:47
void KnockOutGene(const GeneIdType &geneId)
void Copy(const Genome &genome)