#include <genome.h>

Public Member Functions | |
| CGenes (CGenome &Genome) | |
| Construct a new gene set containing genomes drawn from the given underlying genome. | |
| bool | Open (std::istream &istm, bool fCreate=true) |
| Construct a new gene set by loading genes from the given text stream, one per line. | |
| bool | Open (const std::vector< std::string > &vecstrGenes, bool fCreate=true) |
| Construct a new gene set containing the given gene IDs. | |
| void | Filter (const CGenes &GenesExclude) |
| Remove the given genes from the gene set. | |
| size_t | CountAnnotations (const IOntology *pOntology, size_t iTerm, bool fRecursive=true, const CGenes *pBackground=NULL) const |
| Return the number of genes in the set annotated at or, optionally, below the given ontology term. | |
| std::vector< std::string > | GetGeneNames () const |
| Return the primary identifiers of all genes in the set. | |
| bool | Open (const char *szFile, bool fCreate=true) |
| Construct a new gene set by loading genes from the given text file, one per line. | |
| size_t | GetGenes () const |
| Return the number of genes in the set. | |
| bool | IsGene (const std::string &strGene) const |
| Return true if the given name is a primary identifier of a gene in the set. | |
| CGenome & | GetGenome () const |
| Return the gene set's underlying genome. | |
| const CGene & | GetGene (size_t iGene) const |
| Return the gene at the requested index. | |
| size_t | GetGene (const std::string &strGene) const |
| Return the index of the gene with the given primary identifier, or -1 if none exists. | |
Definition at line 355 of file genome.h.
| Sleipnir::CGenes::CGenes | ( | CGenome & | Genome | ) |
Construct a new gene set containing genomes drawn from the given underlying genome.
| Genome | Genome containing all genes which might become members of this gene set. |
Definition at line 451 of file genome.cpp.
| bool Sleipnir::CGenes::Open | ( | std::istream & | istm, | |
| bool | fCreate = true | |||
| ) |
Construct a new gene set by loading genes from the given text stream, one per line.
| istm | Stream containing gene IDs to load, one per line. | |
| fCreate | If true, add unknown genes to the underlying genome; otherwise, unknown gene IDs are ignored. |
GENE1 GENE2 GENE3
Definition at line 481 of file genome.cpp.
References Sleipnir::CGene::GetName().
Referenced by Sleipnir::CPCL::Distance(), Sleipnir::CDatasetCompact::FilterGenes(), Sleipnir::CDat::FilterGenes(), and Open().
| bool Sleipnir::CGenes::Open | ( | const std::vector< std::string > & | vecstrGenes, | |
| bool | fCreate = true | |||
| ) |
Construct a new gene set containing the given gene IDs.
| vecstrGenes | Primary identifiers of genes in the new gene set. | |
| fCreate | If true, add unknown genes to the underlying genome; otherwise, unknown gene IDs are ignored. |
Definition at line 570 of file genome.cpp.
| void Sleipnir::CGenes::Filter | ( | const CGenes & | GenesExclude | ) |
Remove the given genes from the gene set.
| GenesExclude | Genes to be removed from the current gene set. |
Definition at line 597 of file genome.cpp.
References GetGene(), and GetGenes().
| size_t Sleipnir::CGenes::CountAnnotations | ( | const IOntology * | pOntology, | |
| size_t | iTerm, | |||
| bool | fRecursive = true, |
|||
| const CGenes * | pBackground = NULL | |||
| ) | const |
Return the number of genes in the set annotated at or, optionally, below the given ontology term.
| pOntology | Ontology in which annotations are counted. | |
| iTerm | Ontology term at or below which annotations are counted. | |
| fRecursive | If true, count annotations at or below the given term; otherwise, count only direct annotations to the term. | |
| pBackground | If non-null, count only annotations for genes also contained in the given background set. |
Definition at line 539 of file genome.cpp.
References Sleipnir::IOntology::IsAnnotated(), and IsGene().
| vector< string > Sleipnir::CGenes::GetGeneNames | ( | ) | const |
Return the primary identifiers of all genes in the set.
Definition at line 617 of file genome.cpp.
Referenced by Sleipnir::CPCL::Distance().
| bool Sleipnir::CGenes::Open | ( | const char * | szFile, | |
| bool | fCreate = true | |||
| ) | [inline] |
Construct a new gene set by loading genes from the given text file, one per line.
| szFile | File containing gene IDs to load, one per line. | |
| fCreate | If true, add unknown genes to the underlying genome; otherwise, unknown gene IDs are ignored. |
GENE1 GENE2 GENE3
Definition at line 392 of file genome.h.
References Open().
| size_t Sleipnir::CGenes::GetGenes | ( | ) | const [inline] |
Return the number of genes in the set.
Definition at line 405 of file genome.h.
Referenced by Sleipnir::CPCL::Distance(), Filter(), Sleipnir::CDat::FilterGenes(), Sleipnir::CSVM::Learn(), Sleipnir::CDatasetCompact::Open(), and Sleipnir::CDat::Open().
| bool Sleipnir::CGenes::IsGene | ( | const std::string & | strGene | ) | const [inline] |
Return true if the given name is a primary identifier of a gene in the set.
| strGene | Primary gene identifier for which the set is searched. |
Definition at line 422 of file genome.h.
Referenced by CountAnnotations(), Sleipnir::CDatasetCompact::Open(), and Sleipnir::CDat::Open().
| CGenome& Sleipnir::CGenes::GetGenome | ( | ) | const [inline] |
Return the gene set's underlying genome.
Definition at line 433 of file genome.h.
Referenced by Sleipnir::CSVM::Learn().
| const CGene& Sleipnir::CGenes::GetGene | ( | size_t | iGene | ) | const [inline] |
Return the gene at the requested index.
| iGene | Gene index to retrieve. |
Definition at line 450 of file genome.h.
Referenced by Sleipnir::CPCL::Distance(), Filter(), Sleipnir::CDat::FilterGenes(), Sleipnir::CDatasetCompact::Open(), and Sleipnir::CDat::Open().
| size_t Sleipnir::CGenes::GetGene | ( | const std::string & | strGene | ) | const [inline] |
1.5.5