9 #ifndef IMPMULTIFIT_ANCHORS_READER_H
10 #define IMPMULTIFIT_ANCHORS_READER_H
16 #include <IMP/multifit/multifit_config.h>
18 IMPMULTIFIT_BEGIN_NAMESPACE
25 points_=points;edges_=edges;
26 secondary_structure_ps_=Particles();
28 for (
unsigned int i=0;i<points_.size();i++) {
29 consider_point_.push_back(
true);
33 void remove_edges_for_node(
int node_ind) {
36 for(
int i=0;i<(int)edges_.size();i++) {
37 if (! ((edges_[i].first==node_ind) || (edges_[i].second==node_ind))) {
38 new_edges.push_back(edges_[i]);
41 consider_point_[node_ind]=
false;
44 int get_number_of_points()
const {
return points_.size();}
45 int get_number_of_edges()
const {
return edges_.size();}
46 bool get_is_point_considered(
int node_ind)
const {
47 return consider_point_[node_ind];}
48 void show(std::ostream& out=std::cout)
const {
49 out<<
"==== "<<points_.size()<<
" Anchors:"<<std::endl;
50 for(
int i=0;i<(int)points_.size();i++) {
51 out<<points_[i]<<std::endl;
53 out<<
"===="<<edges_.size()<<
" Edges:"<<std::endl;
54 for(
int i=0;i<(int)edges_.size();i++) {
55 out<<
"("<<edges_[i].first<<
","<<edges_[i].second<<
") ";
63 return (secondary_structure_ps_.size()==points_.size());
79 return secondary_structure_ps_;
82 std::vector<bool> consider_point_;
89 IMPMULTIFITEXPORT
AnchorsData read_anchors_data(
const char *txt_filename);
91 void write_txt(
const std::string &txt_filename,
94 void write_cmm(
const std::string &cmm_filename,
95 const std::string &marker_set_name,
98 IMPMULTIFIT_END_NAMESPACE
Decorator for helping deal with a hierarchy.
A decorator for storing secondary structure probabilities. Copyright 2007-2013 IMP Inventors...
bool get_secondary_structure_is_set()
Check if secondary structure is setup.
Storage of anchors (points and edges)
#define IMP_VALUES(Name, PluralName)
Define the type for storing sets of values.
Tools for data points assignment, after anchor point segmentation.
Storage of a model, its restraints, constraints and particles.
void show(Hierarchy h, std::ostream &out=std::cout)
Print out a molecular hierarchy.
Class for storing model, its restraints, constraints, and particles.
IMP::base::Vector< Int > Ints
Standard way to pass a bunch of Int values.