You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following rewrite of a function in QICoreCommon:
define function ToPrevalenceInterval(condition Condition):
if condition.clinicalStatus ~ "active"orcondition.clinicalStatus ~ "recurrence"orcondition.clinicalStatus ~ "relapse" then
Interval[start of ToInterval(condition.onset), end of ToAbatementInterval(condition)]
else if (end of ToAbatementInterval(condition) is null)
then Interval[start of ToInterval(condition.onset), null)
else Interval[start of ToInterval(condition.onset), end of ToAbatementInterval(condition)]
resulted in different behavior than the equivalent formulation with a let:
define function ToPrevalenceInterval(condition Condition):
if condition.clinicalStatus ~ "active"orcondition.clinicalStatus ~ "recurrence"orcondition.clinicalStatus ~ "relapse" then
Interval[start of ToInterval(condition.onset), end of ToAbatementInterval(condition)]
else
(end of ToAbatementInterval(condition)) abatementDate
return if abatementDate is null then
Interval[start of ToInterval(condition.onset), abatementDate)
else
Interval[start of ToInterval(condition.onset), abatementDate]
In theory, the above functions should behave exactly the same. Create a unit test to verify this for all the edges involved:
Condition.clinicalStatus as active and inactive
Condition.onset as a dateTime (null and non-null
Condition.onset as an Interval (null and non-null start and end dates)
Condition.abatement as a dateTime (null and non-null)
Condition.abatement as an Interval (null and non-null start and end dates)
The text was updated successfully, but these errors were encountered:
The following rewrite of a function in QICoreCommon:
resulted in different behavior than the equivalent formulation with a let:
This is related to the following CQLIT ticket: https://oncprojectracking.healthit.gov/support/browse/CQLIT-426
In theory, the above functions should behave exactly the same. Create a unit test to verify this for all the edges involved:
Condition.clinicalStatus as active and inactive
Condition.onset as a dateTime (null and non-null
Condition.onset as an Interval (null and non-null start and end dates)
Condition.abatement as a dateTime (null and non-null)
Condition.abatement as an Interval (null and non-null start and end dates)
The text was updated successfully, but these errors were encountered: