Commit b04efb4c authored by Martin Larralde's avatar Martin Larralde
Browse files

Add PCP descriptors from Venkatarajan *et al.* (2001)

parent 0b075b29
......@@ -68,6 +68,14 @@ class MSWHIMScores(typing.NamedTuple):
mswhim3: float
class PCPDescriptors(typing.NamedTuple):
e1: float
e2: float
e3: float
e4: float
e5: float
class ProtFPDescriptors(typing.NamedTuple):
protfp1: float
protfp2: float
......@@ -1444,6 +1452,48 @@ class Peptide(typing.Sequence[str]):
)
return MSWHIMScores(*out)
def pcp_descriptors(self) -> PCPDescriptors:
"""Compute the Physical-Chemical Properties of a protein sequence.
The PCP descriptors were constructed by performing multidimensional
scaling of 237 physical-chemical properties.
Returns:
`peptides.PCPDescriptors`: The computed average of PCP
descriptors descriptors of all the amino acids in the peptide.
Example:
>>> peptide = Peptide("QWGRRCCGWGPGRRYCVRWC")
>>> for i, pcp in enumerate(peptide.pcp_descriptors()):
... print(f"E{i+1:<3} {pcp: .4f}")
E1 0.0109
E2 0.0381
E3 0.1250
E4 0.0409
E5 -0.1059
References:
- Venkatarajan, M. S., and W. Braun.
*New Quantitative Descriptors of Amino Acids Based on
Multidimensional Scaling of a Large Number of
Physical–Chemical Properties*.
Molecular Modeling Annual. Dec 2001;7(12):445–53.
doi:10.1007/s00894-001-0058-5.
- Venkatarajan, M. S., D. Paris, and M. J. Mullan.
*A Novel Physico-Chemical Property Based Model for Studying
the Effects of Mutation on the Aggregation of Peptides*.
Protein and Peptide Letters. 2009;16(8):991–98.
doi:10.2174/092986609788923220. PMID:19689427.
"""
out = array.array("d")
for i in range(len(tables.PCP_DESCRIPTORS)):
scale = tables.PCP_DESCRIPTORS[f"E{i+1}"]
out.append(
sum(scale.get(aa, 0) for aa in self.sequence) / len(self.sequence)
)
return PCPDescriptors(*out)
def protfp_descriptors(self) -> ProtFPDescriptors:
"""Compute the ProtFP descriptors of a protein sequence.
......
A,0.008
R,0.171
N,0.255
D,0.303
C,-0.132
Q,0.149
E,0.221
G,0.218
H,0.023
I,-0.353
L,-0.267
K,0.243
M,-0.239
F,-0.329
P,0.173
S,0.199
T,0.068
W,-0.296
Y,-0.141
V,-0.274
A,0.134
R,-0.361
N,0.038
D,-0.057
C,0.174
Q,-0.184
E,-0.280
G,0.562
H,-0.177
I,0.071
L,0.018
K,-0.339
M,-0.141
F,-0.023
P,0.286
S,0.238
T,0.147
W,-0.186
Y,-0.057
V,0.136
A,-0.475
R,0.107
N,0.117
D,-0.014
C,0.070
Q,-0.030
E,-0.315
G,-0.024
H,0.041
I,-0.088
L,-0.265
K,-0.044
M,-0.155
F,0.072
P,0.407
S,-0.015
T,-0.015
W,0.389
Y,0.425
V,-0.187
A,-0.039
R,-0.258
N,0.118
D,0.225
C,0.565
Q,0.035
E,0.157
G,0.018
H,0.280
I,-0.195
L,-0.274
K,-0.325
M,0.321
F,-0.002
P,-0.215
S,-0.068
T,-0.132
W,0.083
Y,-0.096
V,-0.196
A,0.181
R,-0.364
N,-0.055
D,0.156
C,-0.374
Q,-0.112
E,0.303
G,0.106
H,-0.021
I,-0.107
L,0.206
K,-0.027
M,0.077
F,0.208
P,0.384
S,-0.196
T,-0.274
W,0.297
Y,-0.091
V,-0.299
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment