Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FlexPepDockingPoseMetrics.hh
Go to the documentation of this file.
1 // -*- mode:c++;tab-width:2;indent-tabs-mode:t;show-trailing-whitespace:t;rm-trailing-spaces:t -*-
2 // vi: set ts=2 noet;
3 //
4 // (C) 199x-2008 Hebrew University, Jerusalem
5 //
6 // (c) Copyright Rosetta Commons Member Institutions.
7 // (c) This file is part of the Rosetta software suite and is made available under license.
8 // (c) The Rosetta software is developed by the contributing members of the Rosetta Commons.
9 // (c) For more information, see http://www.rosettacommons.org. Questions about this can be
10 // (c) addressed to University of Washington UW TechTransfer, email: license@u.washington.edu.
11 /// @file FlexPepDockingPoseMetrics.hh
12 ///
13 /// @brief metrics calculations specific for FlexPepDock (at least for now)
14 /// @date March 29th, 2009
15 /// @author Barak Raveh / Nir London
16 
17 #ifndef INCLUDED_protocols_flexpep_docking_FlexPepDockingPoseMetrics_hh
18 #define INCLUDED_protocols_flexpep_docking_FlexPepDockingPoseMetrics_hh
19 
22 
23 // ObjexxFCL headers
24 #include <ObjexxFCL/FArray1D.fwd.hh>
25 
26 #include <core/types.hh>
29 #include <utility/vector1.hh>
30 
31 
32 namespace protocols {
33 namespace flexpep_docking {
34 
35 using namespace core::pose;
36 using namespace core;
37 
39 {
40 public:
41  typedef bool (*t_predicate_func)(Pose const &, Pose const &, core::Size, core::Size);
42 
43 
45  : flags_(flags)
46  {} // TODO: move to .cc
47 
48  core::Real calc_frac_native_contacts ( Pose const& native,
49  Pose const& final,
50  core::Real threashold ) const;
51 
52  /////////////////////////////////////////////////////////////////////////////
53  /// @begin calculate fractions of atoms that are at the same location as native
54  ///
55  /// @brief calculate fractions of atoms that are at the same location as native
56  ///
57  // @detailed
58  // Calculate fraction of atoms that are less than k Angstroms between native and
59  // final pose, using only residues marked in res_subset, and only atoms qualifying to
60  // predicate function (see core/scoring/rms_utils.hh for definitions of predicates)
61  //
62  // @param
63  // pose1 - the first structure to be assessed
64  // pose2 - the second structure to be assessed
65  // predicate - a predicate on atoms included in the assesment (e.g., CA atoms only)
66  // k - threshold in angstroms of atoms to be included in the assesment
67  // ngood [output] - absolute number of atoms that are less than k Angstroms
68  //
69  // @return
70  // fraction of atoms that are less than k Angstroms between poses
71  ////////////////////////////////////////////////////////////////////////////
72  core::Real calc_frac_atoms_kA_to_native(
73  Pose const& pose1, Pose const& pose2,
74  ObjexxFCL::FArray1D_bool const & res_subset,
75  t_predicate_func predicate,
76  double k,
77  core::Size& ngood
78  ) const;
79 
80 
81  // check all sequential Kmers in the peptide, and output the best RMS Kmer
82  core::Real best_Kmer_rms(
83  Pose const& pose1,
84  Pose const& pose2,
85  t_predicate_func predicate,
86  core::Size k
87  ) const;
88 
89  /////////////////////////////////////////////////////////////////////////////
90  /// @begin calculate phi/psi torsion-RMSD over peptide
91  ///
92  // @detailed
93  // Calculate the RMSD in phi.psi angle over peptide between pose1 and pose2
94  //
95  // @param
96  // pose1 - the first structure to be assessed
97  // pose2 - the second structure to be assessed
98  //
99  // @return
100  // phi/psi torsion-RMSD between peptide backbones
101  ////////////////////////////////////////////////////////////////////////////
102  core::Real calc_phipsi_RMSD(
103  Pose const& pose1,
104  Pose const& pose2,
105  ObjexxFCL::FArray1D_bool const & res_subset
106  ) const;
107 
108 
109  //calculaer different metrics for the interface of the given pose;
110  std::map < std::string, core::Real >
111  calc_interface_metrics
112  (core::pose::Pose & pose, Size rb_jump, core::scoring::ScoreFunctionOP scorefxn);
113 
114  /////////////////////////////////////////
115  // Calculate peptide score with and w/o
116  // fa_ref sequence reference energy
117  /////////////////////////////////////////
118  void
119  calc_pep_scores
120  ( core::pose::Pose const & pose, Real& pepScore, Real& pepScore_noref ) const;
121 
122  // ======== Accessor Methods ========
123 
125  flags_ = flags;
126  }
127 
128 
129 
130 private:
132 
133  // helper method to check if two given residues are within "threashold" of each other
134  bool isInContact ( core::conformation::Residue const res1,
135  core::conformation::Residue const res2,
136  core::Real threashold ) const;
137 
138 
139 }; // end class FlexPepDockingPoseMetrics
140 
141 } // end namespace flexPepDocking
142 } // end namespace protocols
143 
144 #endif