Class: Rafflesia::PocketLigandDistance
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::PocketLigandDistance
- Defined in:
- lib/rafflesia/proteins/pocket_ligand_distance.rb
Constant Summary collapse
- HASH_ATTRS =
{ closest_ligand_atom_name: :closest_ligand_atom_name, closest_ligand_atom_serial: :closest_ligand_atom_serial, distance_angstrom: :distance_angstrom, distance_threshold_angstrom: :distance_threshold_angstrom, is_threshold_hit: :is_threshold_hit, is_within_top_n: :is_within_top_n, is_within_top_n_plus_extra: :is_within_top_n_plus_extra, ligand: :ligand, ligand_id: :ligand_id, pocket_center_angstrom: :pocket_center_angstrom, pocket_id: :pocket_id, pocket_method: :pocket_method, pocket_rank: :pocket_rank }.freeze
Instance Attribute Summary collapse
-
#closest_ligand_atom_name ⇒ Object
Returns the value of attribute closest_ligand_atom_name.
-
#closest_ligand_atom_serial ⇒ Object
Returns the value of attribute closest_ligand_atom_serial.
-
#distance_angstrom ⇒ Object
Returns the value of attribute distance_angstrom.
-
#distance_threshold_angstrom ⇒ Object
Returns the value of attribute distance_threshold_angstrom.
-
#is_threshold_hit ⇒ Object
Returns the value of attribute is_threshold_hit.
-
#is_within_top_n ⇒ Object
Returns the value of attribute is_within_top_n.
-
#is_within_top_n_plus_extra ⇒ Object
Returns the value of attribute is_within_top_n_plus_extra.
-
#ligand ⇒ Object
Returns the value of attribute ligand.
-
#ligand_id ⇒ Object
Returns the value of attribute ligand_id.
-
#pocket_center_angstrom ⇒ Object
Returns the value of attribute pocket_center_angstrom.
-
#pocket_id ⇒ Object
Returns the value of attribute pocket_id.
-
#pocket_method ⇒ Object
Returns the value of attribute pocket_method.
-
#pocket_rank ⇒ Object
Returns the value of attribute pocket_rank.
Instance Method Summary collapse
-
#initialize(json) ⇒ PocketLigandDistance
constructor
A new instance of PocketLigandDistance.
Constructor Details
#initialize(json) ⇒ PocketLigandDistance
Returns a new instance of PocketLigandDistance.
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 39 def initialize(json) super() hash = self.class.normalize(json) @closest_ligand_atom_name = hash[:closest_ligand_atom_name] @closest_ligand_atom_serial = hash[:closest_ligand_atom_serial] @distance_angstrom = hash[:distance_angstrom] @distance_threshold_angstrom = hash[:distance_threshold_angstrom] @is_threshold_hit = hash[:is_threshold_hit] @is_within_top_n = hash[:is_within_top_n] @is_within_top_n_plus_extra = hash[:is_within_top_n_plus_extra] @ligand = hash[:ligand] ? Rafflesia::Ligand.new(hash[:ligand]) : nil @ligand_id = hash[:ligand_id] @pocket_center_angstrom = (hash[:pocket_center_angstrom] || []) @pocket_id = hash[:pocket_id] @pocket_method = hash[:pocket_method] @pocket_rank = hash[:pocket_rank] end |
Instance Attribute Details
#closest_ligand_atom_name ⇒ Object
Returns the value of attribute closest_ligand_atom_name.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def closest_ligand_atom_name @closest_ligand_atom_name end |
#closest_ligand_atom_serial ⇒ Object
Returns the value of attribute closest_ligand_atom_serial.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def closest_ligand_atom_serial @closest_ligand_atom_serial end |
#distance_angstrom ⇒ Object
Returns the value of attribute distance_angstrom.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def distance_angstrom @distance_angstrom end |
#distance_threshold_angstrom ⇒ Object
Returns the value of attribute distance_threshold_angstrom.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def distance_threshold_angstrom @distance_threshold_angstrom end |
#is_threshold_hit ⇒ Object
Returns the value of attribute is_threshold_hit.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def is_threshold_hit @is_threshold_hit end |
#is_within_top_n ⇒ Object
Returns the value of attribute is_within_top_n.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def is_within_top_n @is_within_top_n end |
#is_within_top_n_plus_extra ⇒ Object
Returns the value of attribute is_within_top_n_plus_extra.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def is_within_top_n_plus_extra @is_within_top_n_plus_extra end |
#ligand ⇒ Object
Returns the value of attribute ligand.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def ligand @ligand end |
#ligand_id ⇒ Object
Returns the value of attribute ligand_id.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def ligand_id @ligand_id end |
#pocket_center_angstrom ⇒ Object
Returns the value of attribute pocket_center_angstrom.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def pocket_center_angstrom @pocket_center_angstrom end |
#pocket_id ⇒ Object
Returns the value of attribute pocket_id.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def pocket_id @pocket_id end |
#pocket_method ⇒ Object
Returns the value of attribute pocket_method.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def pocket_method @pocket_method end |
#pocket_rank ⇒ Object
Returns the value of attribute pocket_rank.
24 25 26 |
# File 'lib/rafflesia/proteins/pocket_ligand_distance.rb', line 24 def pocket_rank @pocket_rank end |