This is a read-only mirror of pymolwiki.org

Difference between revisions of "Fetch Path"

From PyMOL Wiki
Jump to navigation Jump to search
m (2 revisions)
m (1 revision)
 
(One intermediate revision by one other user not shown)
Line 4: Line 4:
 
If you have a local copy of the PDB on your machine, say in directory '''/spc/pdb''' then, once you set [[Fetch_Path]] to that directory the [[fetch]] command will look in '''/spc/pdb''' before going to the PDB for your file.  Also, the files fetched from the PDB are stored here once downloaded. PyMOL will only look for files starting with the pdb code in lower case.
 
If you have a local copy of the PDB on your machine, say in directory '''/spc/pdb''' then, once you set [[Fetch_Path]] to that directory the [[fetch]] command will look in '''/spc/pdb''' before going to the PDB for your file.  Also, the files fetched from the PDB are stored here once downloaded. PyMOL will only look for files starting with the pdb code in lower case.
  
= Usage and Examples =
+
= Examples =
 +
 
 +
On Linux or MacOS:
 
<source lang="python">
 
<source lang="python">
set fetch_path, path
 
 
 
set fetch_path, /spc/pdb
 
set fetch_path, /spc/pdb
 +
</source>
  
set fetch_path, D:\mypdbs\
+
On Windows:
 +
<source lang="python">
 +
set fetch_path, D:\mypdbs
 
</source>
 
</source>
  
= Hints =
+
Using <code>~/fetch_path</code>:
If you have a local directory for storing files then put
 
 
<source lang="python">
 
<source lang="python">
set fetch_path, /your/path/here
+
cmd.set('fetch_path', cmd.exp_path('~/fetch_path'), quiet=0)
 
</source>
 
</source>
in your [[pymolrc]] file to auto set this setting.
+
 
 +
= Hints =
 +
 
 +
Put this in your [[pymolrc]] to make it permanent.
  
 
= See Also =
 
= See Also =
[[fetch]]
+
* [[fetch]]
 +
* [[pymolrc]]
  
 
[[Category:Settings]]
 
[[Category:Settings]]

Latest revision as of 05:54, 9 January 2017

Fetch_Path sets the default path that PyMOL uses to load files from before it tries to download them from the PDB.

Details

If you have a local copy of the PDB on your machine, say in directory /spc/pdb then, once you set Fetch_Path to that directory the fetch command will look in /spc/pdb before going to the PDB for your file. Also, the files fetched from the PDB are stored here once downloaded. PyMOL will only look for files starting with the pdb code in lower case.

Examples

On Linux or MacOS:

set fetch_path, /spc/pdb

On Windows:

set fetch_path, D:\mypdbs

Using ~/fetch_path:

cmd.set('fetch_path', cmd.exp_path('~/fetch_path'), quiet=0)

Hints

Put this in your pymolrc to make it permanent.

See Also