Update app.py
Browse files
app.py
CHANGED
|
@@ -54,14 +54,15 @@ def extract_features_app(seq: str) -> pd.DataFrame:
|
|
| 54 |
aromatic = np.mean([(dp[0] in 'FWY') + (dp[1] in 'FWY') for dp in dipeptides_seq]) / 2.0
|
| 55 |
pI = np.mean([h(dp, {aa: 7 + (int(aa in 'KRH') - int(aa in 'DE')) for aa in aa_list}) for dp in dipeptides_seq])
|
| 56 |
instability = np.mean([((dp[0] in 'DEKR') + (dp[1] in 'DEKR')) / 2.0 for dp in dipeptides_seq])
|
| 57 |
-
hydro_moment = np.sqrt(np.mean([(h(dp,
|
| 58 |
aliphatic = np.mean([h(dp, aa_aliphatic) for dp in dipeptides_seq])
|
| 59 |
boman = np.mean([h(dp, aa_boman) for dp in dipeptides_seq])
|
| 60 |
flexibility = np.mean([h(dp, aa_flexibility) for dp in dipeptides_seq])
|
| 61 |
polarizability = np.mean([h(dp, aa_polarizability) for dp in dipeptides_seq])
|
|
|
|
| 62 |
|
| 63 |
physchem_features = [mw, charge, hydro, aromatic, pI, instability,
|
| 64 |
-
hydro_moment, aliphatic, boman, flexibility, polarizability]
|
| 65 |
|
| 66 |
features = dipep_features + physchem_features
|
| 67 |
|
|
|
|
| 54 |
aromatic = np.mean([(dp[0] in 'FWY') + (dp[1] in 'FWY') for dp in dipeptides_seq]) / 2.0
|
| 55 |
pI = np.mean([h(dp, {aa: 7 + (int(aa in 'KRH') - int(aa in 'DE')) for aa in aa_list}) for dp in dipeptides_seq])
|
| 56 |
instability = np.mean([((dp[0] in 'DEKR') + (dp[1] in 'DEKR')) / 2.0 for dp in dipeptides_seq])
|
| 57 |
+
hydro_moment = np.sqrt(np.mean([(h(dp, eisenberg_scale))**2 for dp in dipeptides_seq]))
|
| 58 |
aliphatic = np.mean([h(dp, aa_aliphatic) for dp in dipeptides_seq])
|
| 59 |
boman = np.mean([h(dp, aa_boman) for dp in dipeptides_seq])
|
| 60 |
flexibility = np.mean([h(dp, aa_flexibility) for dp in dipeptides_seq])
|
| 61 |
polarizability = np.mean([h(dp, aa_polarizability) for dp in dipeptides_seq])
|
| 62 |
+
deltag = np.mean([h(dp, aa_deltaG) for dp in dipeptides])
|
| 63 |
|
| 64 |
physchem_features = [mw, charge, hydro, aromatic, pI, instability,
|
| 65 |
+
hydro_moment, aliphatic, boman, flexibility, polarizability, deltag]
|
| 66 |
|
| 67 |
features = dipep_features + physchem_features
|
| 68 |
|