Re: [COOT] Sekvence Alignmutate

2014-11-13 Thread Tim Gruene
Dear Jan,

in principle you can (ab-)use the program mrtailor for this purpose. You
provide the PDB file, the sequence alignment (the way you want it to be
aligned) and it will mutate only the mismatches and leave all other
residues in the PDB file untouched. There is a command line option but
also the GUI mrtailor-gui at
http://shelx.uni-ac.gwdg.de/~tg/research/programs/mrtailor/

Best,
Tim

On 11/12/2014 06:04 PM, Jan Stransky wrote:
 Hi all,
 I have experienced strange behavior of Alignmutate tool. I wanted to
 correct few differences in sequence with it, and there is a place in the
 sequence looking like this:
 orginal sequence:
 XYZDSUVW
 new sequence:
 XYZSPUVW
 
 which ends after Alignmutate like this:
 XYZDS-UVW
 XYZ-SPUVW
 
 and more over numbering of residues changes because of it. And that is
 wrong.
 Therefore, I suggest to incorporate an option Treat sequence rigid or
 something like that, which would just found best match without any
 missing residues. Yes, Mutate residue range did the trick, but it has
 slightly different purpose, I think.
 
 The second problem I have noticed, that it seems that with both
 mutate-sequence tools (Alignmutate, Mutate residue range), it mutates
 all the residues, including those which remains same. That cause
 displacement of correctly placed residues.
 
 Best regards,
 Jan
 

-- 
Dr Tim Gruene
Institut fuer anorganische Chemie
Tammannstr. 4
D-37077 Goettingen

GPG Key ID = A46BEE1A



signature.asc
Description: OpenPGP digital signature


[COOT] key binding to toggle maps

2014-11-13 Thread Oliver Clarke
Hi all,

In case it is of use to any one else, I worked out a key binding which I find 
quite handy and hadn't come across previously, so figured I'd post it here. 

It undisplays all the maps you have displayed if you press it once, and then 
redisplays the same set of maps you had open previously if you press it a 
second time. (There is probably a better way of doing this already built in to 
Coot, but I hadn't been able to find it, and this seems to work.)

I find this useful for quickly toggling the maps off to take a close look at 
the model, then switching them back on, without having to use display manager 
to unselect and reselect the specific subset of maps that were open originally.

Oliver.

Script:

map_disp_flag={0:0}
map_disp_flag_cycle=0
def toggle_map_display():
  global map_disp_flag
  global map_disp_flag_cycle
  if map_disp_flag_cycle==0:
for map_id in map_molecule_list():
  disp_value=map_is_displayed(map_id)
  map_disp_flag[map_id]=disp_value
  if disp_value==1:
set_map_displayed(map_id,0)
map_disp_flag_cycle=1
  elif map_disp_flag_cycle==1:
for map_id in map_molecule_list():
  if map_id not in map_disp_flag:
disp_value=map_is_displayed(map_id)
map_disp_flag[map_id]=disp_value
  if map_disp_flag[map_id]==1:
set_map_displayed(map_id,1)
map_disp_flag_cycle=0
add_key_binding(Toggle map display,`,
lambda: toggle_map_display())