Hi Reza,


If you only need these average map values, not in the context of the atomic model, you can also save the atom attributes to a .defattr file (see documentation of the 'save' command). This file is pretty straightforward to put into a spreadsheet with columns chain/residue/atom/mapvalue, and from there you can calculate your residue-averaged map values (probably easiest with R/python or what have you after a CSV export of the spreadsheet, because for large structures this quickly gets tedious and error-prone to do in a spreadsheet).


Cheers,


Guillaume


From: Elaine Meng via ChimeraX-users <chimerax-users@cgl.ucsf.edu>
Sent: Wednesday, October 29, 2025 2:45:41 AM
To: Reza Khayat
Cc: chimerax-users@cgl.ucsf.edu
Subject: [chimerax-users] Re: Average attribute
 
Hi Reza,
If you use "color byattribute" to color ribbons by an atom attribute, it will calculate residue averages "under the hood" and use those for the color-value mapping of each residue's ribbon segment.  You can also use that command's "average residues" option to color atoms and their molecular surface patches based on the averages over their residues.
<https://rbvi.ucsf.edu/chimerax/docs/user/commands/color.html#byattribute>

However, ChimeraX does not have an "attribute calculator" user interface.  As far as I know, obtaining some kind of output of those residue-average values would require python scripting.  Somebody else would have to advise on that (beyond my skill set, sorry).

Best,
Elaine
-----
Elaine C. Meng, Ph.D.
UCSF Chimera(X) team
Resource for Biocomputing, Visualization, and Informatics
Department of Pharmaceutical Chemistry
University of California, San Francisco

> On Oct 28, 2025, at 6:19 PM, Reza Khayat via ChimeraX-users <chimerax-users@cgl.ucsf.edu> wrote:
>
> Hi,
>
> How do I average atom attributes to residue attributes? Let's assume the attributes name is mapvalues. Thanks.
>
> Best wishes,
> Reza
>
> Reza Khayat, PhD
> City College of New York
> Department of Chemistry and Biochemistry


_______________________________________________
ChimeraX-users mailing list -- chimerax-users@cgl.ucsf.edu
To unsubscribe send an email to chimerax-users-leave@cgl.ucsf.edu
Archives: https://mail.cgl.ucsf.edu/mailman/archives/list/chimerax-users@cgl.ucsf.edu/

VARNING: Klicka inte på länkar och öppna inte bilagor om du inte känner igen avsändaren och vet att innehållet är säkert.
CAUTION: Do not click on links or open attachments unless you recognise the sender and know the content is safe.

Page Title







När du har kontakt med oss på Uppsala universitet med e-post så innebär det att vi behandlar dina personuppgifter. För att läsa mer om hur vi gör det kan du läsa här: http://www.uu.se/om-uu/dataskydd-personuppgifter/

E-mailing Uppsala University means that we will process your personal data. For more information on how this is performed, please read here: http://www.uu.se/en/about-uu/data-protection-policy