@@ -195,13 +195,15 @@ select
195195
196196 , case
197197 when bun_max is null then null
198- when bun_max >= 55 .0 then 4
199- when bun_max >= 36 .0 then 3
200- when bun_max >= 29 .0 then 2
201- when bun_max >= 7 .50 then 1
202- when bun_min < 3 .5 then 1
203- when bun_max >= 3 .5 and bun_max < 7 .5
204- and bun_min >= 3 .5 and bun_min < 7 .5
198+ -- SAPS 1984 publishes urea in mmol/L; MIMIC BUN is mg/dL (×2.8).
199+ -- Same conversion as PhysioNet Challenge 2012 saps_score.m.
200+ when bun_max >= 154 .0 then 4
201+ when bun_max >= 100 .8 then 3
202+ when bun_max >= 81 .2 then 2
203+ when bun_max >= 21 .0 then 1
204+ when bun_min < 9 .8 then 1
205+ when bun_max >= 9 .8 and bun_max < 21 .0
206+ and bun_min >= 9 .8 and bun_min < 21 .0
205207 then 0
206208 end as bun_score
207209
@@ -231,14 +233,15 @@ select
231233
232234 , case
233235 when glucose_max is null then null
234- when glucose_max >= 44 .5 then 4
235- when glucose_min < 1 .6 then 4
236- when glucose_max >= 27 .8 then 3
237- when glucose_min < 2 .8 then 3
238- when glucose_min < 3 .9 then 2
239- when glucose_max >= 14 .0 then 1
240- when glucose_max >= 3 .9 and glucose_max < 14 .0
241- and glucose_min >= 3 .9 and glucose_min < 14 .0
236+ -- SAPS 1984 glucose is mmol/L; MIMIC glucose is mg/dL (×18).
237+ when glucose_max >= 801 .0 then 4
238+ when glucose_min < 28 .8 then 4
239+ when glucose_max >= 500 .4 then 3
240+ when glucose_min < 50 .4 then 3
241+ when glucose_min < 70 .2 then 2
242+ when glucose_max >= 252 .0 then 1
243+ when glucose_max >= 70 .2 and glucose_max < 252 .0
244+ and glucose_min >= 70 .2 and glucose_min < 252 .0
242245 then 0
243246 end as glucose_score
244247
0 commit comments