[chimerax-users] Color Model by Another Model

Anderson, Jacob jacob_r_anderson at hms.harvard.edu
Sat Jan 15 04:17:46 PST 2022


Dear Elaine and Tom,

Thank you for the different approaches. I think I have a better idea how to use "info" and selective residues/atoms to get the chain color of all the chains in my model. And thereby solve this problem with chimerax command approach.

I also tried the python script Tom made. It worked brilliantly to map the colors. Thank you.

Jacob
________________________________
From: Tom Goddard <goddard at sonic.net>
Sent: Friday, January 14, 2022 10:51 PM
To: Anderson, Jacob <jacob_r_anderson at hms.harvard.edu>
Cc: chimerax-users at cgl.ucsf.edu <chimerax-users at cgl.ucsf.edu>
Subject: Re: [chimerax-users] Color Model by Another Model

Hi Jacob,

Do the corresponding chains have the same chain ID letters (ie A matches A, B matches B, ...).  The "color bychain" always gives the same color for the same chain id so if you used that they would get the same colors.  Similarly "color bypolymer" gives the same color to chains with the same sequence, so if your matching chains had the same sequence that would give the same colors.

But if you gave custom colors to the chains then there is no command to copy them.  Some Python code could do it.  Here is an example of that.

https://rbvi.github.io/chimerax-recipes/copycolors/copycolors.html<https://urldefense.proofpoint.com/v2/url?u=https-3A__rbvi.github.io_chimerax-2Drecipes_copycolors_copycolors.html&d=DwMFAg&c=WO-RGvefibhHBZq3fL85hQ&r=WAfw3qrUG1ShU2YpwE9tWl1TX9X2iVUkDLLxcqiRjEpY2mHnzFciBB5rhLWZHqpa&m=qFtcOqmVWTjXdB04x0OmeXDUwf9egUTYZZDOsaxnenCer5eFTaa4bO9Mi_lnQLYr&s=SbAFPkjp1fC5jYBvyWRgpFUivxGzA1PkGFKbqh0EujQ&e=>

  Tom

[cid:7A7546E2-CA80-40DB-982E-65C729A4E377]

On Jan 14, 2022, at 5:57 PM, Anderson, Jacob via ChimeraX-users <chimerax-users at cgl.ucsf.edu<mailto:chimerax-users at cgl.ucsf.edu>> wrote:

I have a use case where I would like to color chains of model X by the chains of model Y (they are duplicates). What might be the best way to do this?

For example, I thought there may be a way to run something like: "info colors #1 byChain" to get the colors of all chains printed to the log like "#1/A blue, #1/B red . . .". Then one could easily change #1 to #2 with sed in a text editor.  Does a tool like that exist in ChimeraX? Or has might anyone have tips for coloring a model's chain by another models chains?

jacob




_______________________________________________
ChimeraX-users mailing list
ChimeraX-users at cgl.ucsf.edu<mailto:ChimeraX-users at cgl.ucsf.edu>
Manage subscription:
https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users<https://urldefense.proofpoint.com/v2/url?u=https-3A__plato.cgl.ucsf.edu_mailman_listinfo_chimerax-2Dusers&d=DwMFAg&c=WO-RGvefibhHBZq3fL85hQ&r=WAfw3qrUG1ShU2YpwE9tWl1TX9X2iVUkDLLxcqiRjEpY2mHnzFciBB5rhLWZHqpa&m=qFtcOqmVWTjXdB04x0OmeXDUwf9egUTYZZDOsaxnenCer5eFTaa4bO9Mi_lnQLYr&s=lrmPiajIsOEprh6NSe8CSivAaQzH27wJ9V7b39vy_BU&e=>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://plato.cgl.ucsf.edu/pipermail/chimerax-users/attachments/20220115/c11806b6/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 6s8e_6s6b.png
Type: image/png
Size: 880733 bytes
Desc: 6s8e_6s6b.png
URL: <http://plato.cgl.ucsf.edu/pipermail/chimerax-users/attachments/20220115/c11806b6/attachment-0001.png>


More information about the ChimeraX-users mailing list