Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Per-residue data #3

Closed
multimeric opened this issue Apr 20, 2022 · 1 comment
Closed

Per-residue data #3

multimeric opened this issue Apr 20, 2022 · 1 comment
Labels
enhancement New feature or request

Comments

@multimeric
Copy link

It seems that the API can only output single statistics for the entire peptide chain, but I'm interested in statistics for each residue individually. I'm wondering if it might be possible to output an array/list from some of these functions instead of always averaging them as is done now.

@althonos
Copy link
Owner

althonos commented Sep 1, 2022

Hi @multimeric

In v0.3.0 I added the Peptide.profile function, which takes a per-residue table and an optional window size (default being 1, so no window averaging). You can get it to obtain per-residue data from any of the tables in peptides.tables, or from your own.

For instance, to get per-residue values of the VHSE1 descriptor:

>>> p = peptides.Peptide("SDKEVDEVDAALSDLEITLE")
>>> p.profile(peptides.tables.VHSE["VHSE1"])
[-0.67, -1.15, -1.17, -1.18, 0.76, -1.15, -1.18, 0.76, -1.15, 0.15, 0.15, 1.36, -0.67, -1.15, 1.36, -1.18, 1.27, -0.34, 1.36, -1.18]

@althonos althonos closed this as completed Sep 1, 2022
@althonos althonos added the enhancement New feature or request label Sep 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants