IMP logo
IMP Reference Guide  2.17.0
The Integrative Modeling Platform
protein_ligand_score.h
Go to the documentation of this file.
1 /**
2  * \file IMP/atom/protein_ligand_score.h
3  * \brief Functions to score protein-ligand interactions
4  *
5  * Copyright 2007-2022 IMP Inventors. All rights reserved.
6  *
7  */
8 
9 #ifndef IMPATOM_PROTEIN_LIGAND_SCORE_H
10 #define IMPATOM_PROTEIN_LIGAND_SCORE_H
11 
12 #include <IMP/atom/atom_config.h>
13 #include "Hierarchy.h"
15 #include <IMP/Model.h>
16 #include <IMP/Particle.h>
17 #include <IMP/Restraint.h>
18 #include <IMP/PairScore.h>
20 #include <IMP/algebra/Vector3D.h>
21 #include <IMP/file.h>
22 #include <limits>
23 
24 IMPATOM_BEGIN_NAMESPACE
25 
26 /** \name Protein-ligand scoring
27  \anchor protein_ligand
28 
29  \imp provides a statistical scoring function for scoring
30  protein-ligand complexes. See the
31  [Ligand Score application](@ref impligand_score) for more information.
32  @{
33  */
35 
36 #ifndef SWIG
37 /** The marker to identify the atom types.*/
40 #else
41 class ProteinLigandType;
42 #endif
43 
44 /** add_protein_ligand_score_data() must be called on the molecules
45  containing the atoms before the PairScore is used in order
46  to properly initialize the particles.
47 
48  The default library to use is \c protein_ligand_rank_score.lib.
49  \imp also provides \c protein_ligand_pose_score.lib which can be
50  found at IMP::atom::get_data_path("protein_ligand_pose_score.lib").
51 */
52 class IMPATOMEXPORT ProteinLigandAtomPairScore
53  : public core::StatisticalPairScore<ProteinLigandType, true, false> {
54  friend class ProteinLigandRestraint;
56  double threshold_;
57 
58  public:
59  ProteinLigandAtomPairScore(double threshold =
60  std::numeric_limits<double>::max());
61  ProteinLigandAtomPairScore(double threshold, TextInput data_file);
62  double get_maximum_distance() const { return threshold_; }
63 };
64 
66 
67 //! Score a pair of molecules.
68 /** \see ProteinLigandAtomPairScore for simply scoring the atom pairs.
69  */
70 class IMPATOMEXPORT ProteinLigandRestraint : public container::PairsRestraint {
71  void initialize(Hierarchy protein, Hierarchy ligand);
72 
73  public:
75  double threshold = std::numeric_limits<double>::max());
76  ProteinLigandRestraint(Hierarchy protein, Hierarchy ligand, double threshold,
77  TextInput data_file);
78 };
79 
81 
82 /** Add the data needed to use ProteinLigandAtomPairScore with the passed
83  Hierarchy.*/
84 IMPATOMEXPORT void add_protein_ligand_score_data(Hierarchy h);
85 
86 /** @} */
87 IMPATOM_END_NAMESPACE
88 
89 #endif /* IMPATOM_PROTEIN_LIGAND_SCORE_H */
Apply a PairScore to each Pair in a list.
Storage of a model, its restraints, constraints and particles.
Handling of file input/output.
A more IMP-like version of the std::vector.
Definition: Vector.h:40
Score a pair of molecules.
Decorator for helping deal with a hierarchy of molecules.
#define IMP_VALUES(Name, PluralName)
Define the type for storing sets of values.
Definition: value_macros.h:23
The standard decorator for manipulating molecular structures.
Define PairScore.
A base class for Keys.
Definition: Key.h:44
void add_protein_ligand_score_data(Hierarchy h)
Classes to handle individual model particles. (Note that implementation of inline functions is in int...
#define IMP_OBJECTS(Name, PluralName)
Define the types for storing lists of object pointers.
Definition: object_macros.h:44
Key< 783462 > ProteinLigandType
Simple 3D vector class.
Abstract base class for all restraints.
Functions to read mol2s.
Applies a PairScore to each Pair in a list.