Advertisement
ZaynerTech

VMD TCL Position Restraint Generator

Jan 17th, 2013
230
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
TCL 0.49 KB | None | 0 0
  1. # Generate position Restrained files for namd simulations
  2. # In VMD:
  3. # source gen_pr
  4. # gen_pr (# of restraint files to generate)
  5. # The files are named #.pdb
  6. # In the beta(B-factor) field a number is placed
  7. # as a force restraint for each atom
  8. # can be changed to CA by changing "set a.." line
  9.  
  10.  
  11. proc gen_pr { num } {
  12.    set a [atomselect top protein]
  13.    set b [atomselect top all]
  14.  
  15.     for {set i $num } {$i >= 0} {incr i -1} {
  16.  
  17.         $a set beta $i
  18.         $b writepdb $i.pdb  
  19.     }
  20.    
  21.  }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement