00001 00002 #include "../headers/pscoring.h" 00003 00004 /* 00005 00006 ## GENERAL INFORMATION 00007 ## 00008 ## FILE pscoring.c 00009 ## AUTHORS P. Schmidtke and V. Le Guilloux 00010 ## LAST MODIFIED 28-11-08 00011 ## 00012 ## SPECIFICATIONS 00013 ## 00014 ## This file stores scoring functions for pockets. 00015 ## 00016 ## MODIFICATIONS HISTORY 00017 ## 00018 ## 21-01-09 (v) Added new scoring function 00019 ## 28-11-08 (v) Created + Comments UTD 00020 ## 00021 ## TODO or SUGGESTIONS 00022 ## 00023 ## 00024 00025 */ 00026 00027 /* 00028 COPYRIGHT DISCLAIMER 00029 00030 Vincent Le Guilloux, Peter Schmidtke and Pierre Tuffery, hereby 00031 disclaim all copyright interest in the program “fpocket” (which 00032 performs protein cavity detection) written by Vincent Le Guilloux and Peter 00033 Schmidtke. 00034 00035 Vincent Le Guilloux 28 November 2008 00036 Peter Schmidtke 28 November 2008 00037 Pierre Tuffery 28 November 2008 00038 00039 GNU GPL 00040 00041 This file is part of the fpocket package. 00042 00043 fpocket is free software: you can redistribute it and/or modify 00044 it under the terms of the GNU General Public License as published by 00045 the Free Software Foundation, either version 3 of the License, or 00046 (at your option) any later version. 00047 00048 fpocket is distributed in the hope that it will be useful, 00049 but WITHOUT ANY WARRANTY; without even the implied warranty of 00050 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00051 GNU General Public License for more details. 00052 00053 You should have received a copy of the GNU General Public License 00054 along with fpocket. If not, see <http://www.gnu.org/licenses/>. 00055 00056 **/ 00057 00058 /** 00059 ## FUNCTION: 00060 score_pocket2 00061 00062 ## SPECIFICATION: 00063 Set a score to a given pocket. The current scoring function has been determined 00064 using a logistic regression based on an analysis of pocket descriptors. 00065 00066 00067 ## PARAMETRES: 00068 @ s_pocket *pocket: The pocket 00069 00070 ## RETURN: 00071 float: The score 00072 00073 */ 00074 float score_pocket(s_desc *pdesc) 00075 { 00076 float score ; 00077 00078 /** 00079 * Data to use for mean-center normalization step: N = 2 00080 * MEAN SD 00081 * nas_norm 0.183 0.243 00082 * apol_asprop_norm 0.402 0.259 00083 * mean_loc_hd_norm 0.334 0.261 00084 * polarity_score 7.193 4.197 00085 * polarity_score_norm 0.291 0.242 00086 * as_density 5.194 1.707 00087 * as_density_norm 0.387 0.252 00088 * 00089 */ 00090 00091 /* 00092 Using m 3.0 M 6.0 D 1.73 i 25 we have for the training set this PLS model 00093 having 4 components 00094 00095 CURRENT !!!!!!!!!!!!!!!!! SCORING 1 00096 */ 00097 /* 00098 Perf: 00099 Scoring function 1: 00100 CPP OVL 00101 Data T1/T3 | T1/T3 00102 00103 Train : 62/86 - 65/89 00104 PP holo : 79/92 - 79/90 00105 PP apo : 69/90 00106 Cheng : 70/85 - 70/100 00107 Gold : 69/90 - 71/90 00108 */ 00109 00110 00111 score = 00112 -1.50335 00113 +30.27950 * (float)pdesc->nas_norm 00114 -3.40435 * (float)pdesc->prop_asapol_norm 00115 +11.04704 * (float)pdesc->mean_loc_hyd_dens_norm 00116 +1.18610 * (float)pdesc->polarity_score 00117 -2.01214 * (float)pdesc->as_density ; 00118 00119 score = 00120 -0.65784 00121 +29.78270 * (float)pdesc->nas_norm 00122 -4.06632 * (float)pdesc->prop_asapol_norm 00123 +11.72346 * (float)pdesc->mean_loc_hyd_dens_norm 00124 +1.16349 * (float)pdesc->polarity_score 00125 -2.06835 * (float)pdesc->as_density ; 00126 00127 00128 /* 00129 Using m 3.0 M 6.0 D 1mean_loc_hyd_dens_norm.73 i 25 n 2 we have for the training set this PLS model 00130 having 4 components 00131 00132 SCORING 2 00133 */ 00134 /* 00135 Perf: 00136 Scoring function 1: 00137 CPP OVL 00138 Data T1/T3 | T1/T3 00139 00140 Train : 62/86 - 65/89 00141 PP holo : 79/92 - 79/90 00142 PP apo : 69/90 00143 Cheng : 70/85 - 70/100 00144 Gold : 69/91 - 71/90 00145 */ 00146 00147 /* 00148 score = 00149 -0.65784 00150 +29.78270 * (float)pdesc->nas_norm 00151 -4.06632 * (float)pdesc->prop_asapol_norm 00152 +11.72346 * (float)pdesc->mean_loc_hyd_dens_norm 00153 +1.16349 * (float)pdesc->polarity_score 00154 -2.06835 * (float)pdesc->as_density ; 00155 */ 00156 /* 00157 Using m 3.0 M 6.0 D 1mean_loc_hyd_dens_norm.73 i 25 n 3 we have for the training set this PLS model 00158 having 4 components 00159 00160 SCORING 3 00161 */ 00162 /* 00163 Perf: 00164 Scoring function 1: 00165 CPP OVL 00166 Data T1/T3 | T1/T3 00167 00168 Train : 59/84 - 64/89 00169 PP holo : 79/94 - 81/94 00170 PP apo : 69/90 00171 Cheng : 70/85 - 75/100 00172 Gold : 71/91 - 72/89 00173 */ 00174 00175 /* 00176 score = 00177 -1.48906 00178 +29.54059 * (float)pdesc->nas_norm 00179 +10.73666 * (float)pdesc->mean_loc_hyd_dens_norm 00180 -3.30562 * (float)pdesc->prop_asapol_norm 00181 +1.15711 * (float)pdesc->polarity_score 00182 -1.94912 * (float)pdesc->as_density ; 00183 */ 00184 00185 /* ON GOLD 00186 Using m 3.0 M 6.0 D 1mean_loc_hyd_dens_norm.73 i 25 n 2 we have for the training set this PLS model 00187 having 4 components 00188 00189 SCORING 4 00190 */ 00191 /* 00192 Perf: 00193 Scoring function 1: 00194 CPP OVL 00195 Data T1/T3 | T1/T3 00196 00197 Train : 59/84 - 64/89 00198 PP holo : 79/94 - 81/94 00199 PP apo : 71/90 00200 Cheng : 70/85 - 75/100 00201 Gold : 69/91 - 71/90 00202 */ 00203 00204 /* 00205 score = 00206 -1.29456 00207 +33.45117 * (float)pdesc->nas_norm 00208 +17.78868 * (float)pdesc->mean_loc_hyd_dens_norm 00209 -5.23046 * (float)pdesc->prop_asapol_norm 00210 +1.07977 * (float)pdesc->polarity_score 00211 -2.00073 * (float)pdesc->as_density ; 00212 */ 00213 00214 /* ON GOLD 00215 Using m 3.0 M 6.0 D 1mean_loc_hyd_dens_norm.73 i 25 n 3 we have for the training set this PLS model 00216 having 4 components 00217 00218 SCORING 5 00219 */ 00220 00221 /* 00222 Perf: 00223 Scoring function 1: 00224 CPP OVL 00225 Data T1/T3 | T1/T3 00226 00227 Train : 62/86 - 65/89 00228 PP holo : 79/90 - 79/88 00229 PP apo : 67/90 00230 Cheng : 70/85 - 70/100 00231 Gold : 70/91 - 71/90 00232 */ 00233 /* 00234 00235 score = 00236 -2.29256 00237 +33.86433 * (float)pdesc->nas_norm 00238 +17.55332 * (float)pdesc->mean_loc_hyd_dens_norm 00239 -4.90910 * (float)pdesc->prop_asapol_norm 00240 +1.11252 * (float)pdesc->polarity_score 00241 -1.88681 * (float)pdesc->as_density; 00242 */ 00243 00244 /* 00245 score = 00246 -0.04719 00247 +27.28918 * (float)pdesc->nas_norm 00248 -3.28306 * (float)pdesc->prop_asapol_norm 00249 +11.24130 * (float)pdesc->mean_loc_hyd_dens_norm 00250 +1.24804 * (float)pdesc->polarity_score 00251 -2.63044 * (float)pdesc->as_density 00252 +5.42051 * (float)pdesc->as_max_dst_norm ; 00253 */ 00254 00255 00256 00257 return score ; 00258 } 00259 00260 00261 /** 00262 ## FUNCTION: 00263 drug_score_pocket 00264 00265 ## SPECIFICATION: 00266 Set a drug score to a given pocket. The current scoring function has been determined 00267 using a logistic regression based on an analysis of pocket descriptors. 00268 00269 00270 ## PARAMETRES: 00271 @ s_desc *pdesc: The pocket descriptors 00272 00273 ## RETURN: 00274 float: The score 00275 00276 */ 00277 float drug_score_pocket(s_desc *pdesc) 00278 { 00279 /* 00280 float b10=-5.088898; 00281 float b11=6.367213; 00282 float b20=-2.294515; 00283 float b21=0.047952857; 00284 float b30=-2.140685; 00285 float b31=2.362326 ; 00286 float b0=-6.040274; 00287 float b1= 5.076534 ; 00288 float b2= 4.9172461; 00289 float b3= 3.300904; 00290 */ 00291 00292 float score ; 00293 float l1,l2,l3; 00294 float b10=-5.140959; 00295 float b11=6.579424; 00296 float b20=-2.668468; 00297 float b21=0.05581948; 00298 float b30=-2.445236; 00299 float b31=2.762473 ; 00300 float b0=-6.238031; 00301 float b1= 4.592376 ; 00302 float b2= 5.717858; 00303 float b3= 3.985070; 00304 l1=exp(b10+b11*(float)pdesc->mean_loc_hyd_dens_norm)/(1.0+exp(b10+b11*(float)pdesc->mean_loc_hyd_dens_norm)); 00305 l2=exp(b20+b21*(float)pdesc->hydrophobicity_score)/(1.0+exp(b20+b21*(float)pdesc->hydrophobicity_score)); 00306 l3=exp(b30+b31*(float)pdesc->polarity_score_norm)/(1.0+exp(b30+b31*(float)pdesc->polarity_score_norm)); 00307 00308 score=exp(b0+b1*l1+b2*l2+b3*l3)/(1.0+exp(b0+b1*l1+b2*l2+b3*l3)); 00309 00310 /*fprintf(stdout,"drug score %.3f %.3f %.3f %.3f %.3f %.3f %.3f\n",pdesc->mean_loc_hyd_dens_norm,pdesc->hydrophobicity_score, pdesc->polarity_score_norm,l1,l2,l3,score);*/ 00311 return score ; 00312 }