Difference between revisions of "Get raw distances"

From PyMOLWiki
Jump to navigation Jump to search
(created)
 
(Infobox psico)
 
(4 intermediate revisions by 2 users not shown)
Line 4: Line 4:
 
|author    = [[User:TakanoriNakane|Takanori Nakane]] and [[User:Speleo3|Thomas Holder]]
 
|author    = [[User:TakanoriNakane|Takanori Nakane]] and [[User:Speleo3|Thomas Holder]]
 
|license  = BSD-2-Clause
 
|license  = BSD-2-Clause
 +
}}
 +
 +
{{Infobox psico
 +
|module    = psico.querying
 
}}
 
}}
  
 
[[get_raw_distances]] can dump distance objects, created with [[distance]].
 
[[get_raw_distances]] can dump distance objects, created with [[distance]].
 +
 +
This script also provides the command '''select_distances''', which selects atoms from distance objects.
 +
 +
''Warning: the atoms are hashed by coordinates; this could cause issues if coordinates are altered after distance objects have been created (see also [[dynamic_measures]] setting).''
 +
 +
== Usage ==
 +
 +
get_raw_distances [ names [, state [, selection ]]]
 +
 +
select_distances [ names [, name [, state [, selection [, cutoff ]]]]]
  
 
== Arguments ==
 
== Arguments ==
Line 23: Line 37:
  
 
# dump (model,index) information
 
# dump (model,index) information
get_raw_distances get_raw_distances
+
get_raw_distances iface_hbonds
 +
</syntaxhighlight>
 +
 
 +
== Example Atom Selection ==
 +
 
 +
<syntaxhighlight lang="python">
 +
# select atoms
 +
select_distances iface_hbonds, hbsele
 +
 
 +
# nice representation
 +
set cartoon_side_chain_helper
 +
set sphere_scale, 0.5
 +
as cartoon, 2xwu
 +
show sticks, byres hbsele
 +
show spheres, hbsele
 
</syntaxhighlight>
 
</syntaxhighlight>
  
Line 29: Line 57:
  
 
* [[distance]]
 
* [[distance]]
 +
* [[dynamic_measures]]
 
* [[find_pairs]]
 
* [[find_pairs]]
 
* [[get_raw_alignment]]
 
* [[get_raw_alignment]]
  
 
[[Category:Script Library]]
 
[[Category:Script Library]]
 +
[[Category:ObjSel_Scripts]]
 +
[[Category:Pymol-script-repo]]

Latest revision as of 03:48, 31 July 2012

Type Python Module
Download get_raw_distances.py
Author(s) Takanori Nakane and Thomas Holder
License BSD-2-Clause
This code has been put under version control in the project Pymol-script-repo

Included in psico
This command or function is available from psico, which is a PyMOL extension.

Module psico.querying

get_raw_distances can dump distance objects, created with distance.

This script also provides the command select_distances, which selects atoms from distance objects.

Warning: the atoms are hashed by coordinates; this could cause issues if coordinates are altered after distance objects have been created (see also dynamic_measures setting).

Usage

get_raw_distances [ names [, state [, selection ]]]
select_distances [ names [, name [, state [, selection [, cutoff ]]]]]

Arguments

  • names = string: names of distance objects (no wildcards!) {default: all measurement objects}
  • state = integer: object state {default: 1}
  • selection = string: atom selection {default: all}

Example

fetch 2xwu, async=0

# interface polar contacts
distance iface_hbonds, chain A, chain B, mode=2

# dump (model,index) information
get_raw_distances iface_hbonds

Example Atom Selection

# select atoms
select_distances iface_hbonds, hbsele

# nice representation
set cartoon_side_chain_helper
set sphere_scale, 0.5
as cartoon, 2xwu
show sticks, byres hbsele
show spheres, hbsele

See Also