Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion mimic-iii/concepts/durations/neuroblock_dose.sql
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,11 @@ select
)
= 1 then 1

when (CHARTTIME - (LAG(CHARTTIME, 1) OVER (partition by icustay_id, drug order by charttime))) > (interval '8 hours') then 1
when DATETIME_DIFF(
CHARTTIME,
LAG(CHARTTIME, 1) OVER (partition by icustay_id, drug order by charttime),
HOUR
) > 8 then 1
else null
end as drug_start

Expand Down
Loading