CAFE
Computational Analysis of gene Family Evolution
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
gene_family.h
Go to the documentation of this file.
1 #ifndef GENE_FAMILY_H_4DEBB8E1_1D4E_4AA9_8B27_4D8FD59507A6
2 #define GENE_FAMILY_H_4DEBB8E1_1D4E_4AA9_8B27_4D8FD59507A6
3 
4 #include <vector>
5 #include <string>
6 #include <iosfwd>
7 
8 extern "C" {
9 #include "cafe.h"
10 #include "family.h"
11 }
12 
13 const int REGULAR_WHITESPACE = 0;
14 const int COMMA_AS_WHITESPACE = 1;
15 
16 std::vector<std::string> tokenize(std::string s, int flags);
17 
18 pCafeFamily cafe_family_init(const std::vector<std::string>& species_list);
19 pCafeFamily load_gene_families(std::istream& ist, char separator, int max_size);
21 
23 {
24  std::string id;
25  std::string desc;
26  std::vector<int> values;
27 
29  {
30 
31  }
32 
33  gene_family(std::string i, std::string d, std::vector<int> v) : id(i), desc(d), values(v)
34  {
35  }
36 };
37 
38 std::istream& operator>>(std::istream& ist, gene_family& fam);
39 
40 void cafe_family_add_item(pCafeFamily pcf, const gene_family& gf);
42 
43 int log_cluster_membership(pCafeFamily pcf, int k_value, double **p_z_membership, std::ostream& log);
44 
46 int cafe_family_get_index(pCafeFamily pcf, const char* szid);
47 #endif
int log_cluster_membership(pCafeFamily pcf, int k_value, double **p_z_membership, std::ostream &log)
Definition: gene_family.cpp:345
std::vector< std::string > tokenize(std::string s, int flags)
std::string desc
Definition: gene_family.h:25
std::vector< int > values
Definition: gene_family.h:26
void cafe_family_add_item(pCafeFamily pcf, const gene_family &gf)
Definition: gene_family.cpp:219
const int COMMA_AS_WHITESPACE
Definition: gene_family.h:14
Definition: gene_family.h:22
void cafe_family_reset_maxlh(pCafeFamily pcf)
Definition: gene_family.cpp:364
gene_family()
Definition: gene_family.h:28
int cafe_family_get_index(pCafeFamily pcf, const char *szid)
Definition: gene_family.cpp:375
const int REGULAR_WHITESPACE
Definition: gene_family.h:13
gene_family(std::string i, std::string d, std::vector< int > v)
Definition: gene_family.h:33
std::istream & operator>>(std::istream &ist, gene_family &fam)
Definition: gene_family.cpp:163
Represents a single gene family and the number of members of that family that exist in each species...
Definition: cafe.h:11
pCafeFamily cafe_family_init(const std::vector< std::string > &species_list)
Definition: gene_family.cpp:119
pCafeFamily load_gene_families(std::istream &ist, char separator, int max_size)
Definition: gene_family.cpp:176
Structure representing a matrix of values of family sizes.
Definition: family.h:88
void cafe_family_item_free(pCafeFamilyItem pitem)
Definition: gene_family.cpp:245
void cafe_family_free(pCafeFamily pcf)
Definition: gene_family.cpp:142
std::string id
Definition: gene_family.h:24