Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

     Let measured_weight_LN: CD = CD{code = '29463-7', codeSystem = '2.16.840.1.113883.6.1', codeSystemName ='LN'}
     Let measured_height_LN: CD = CD{code = '8302-2', codeSystem = '2.16.840.1.113883.6.1', codeSystemName ='LN'}
     Let measured_waist_LN: CD = CD{code = '8280-0', codeSystem = '2.16.840.1.113883.6.1', codeSystemName ='LN'}
     Let sys_BP_LN: CD = CD{code = '8480-6',c odeSystemcodeSystem = '2.16.840.1.113883.6.1', codeSystemName ='LN'}
     Let diast_BP_LN: CD = CD{code = '8462-4', codeSystem = '2.16.840.1.113883.6.1', codeSystemName ='LN'}

...

     --TG HDL ratio
Let trig_HDL_Ratio : Real = If last_trigObservation.oclIsDefined() and last_hdlObservation.oclIsDefined() then
last_trigObservation.value.oclAsType(PQ).value / last_hdlObservation.value.oclAsType(PQ).value
else null endif
Let trig_HDL_Ratio_raised: Boolean = If last_trigObservation.oclIsDefined() and last_hdlObservation.oclIsDefined() then
If last_trigObservation.value.oclAsType(PQ).value / last_hdlObservation.value.oclAsType(PQ).value > 2
then True
else False endif
else False endif Let trig_HDL_ratio_asChar: String = If trig_HDL_Ratio.oclIsDefined() then trig_HDL_Ratio.toChar() else '' endif

     Prepare comments:

...

     Let trig_HDL_ratio_comment1: String = If trig_HDL_Ratio_raised then
        '\nTriglyceride-HDL ratio is ' else '' endif
     Let trig_HDL_ratio_comment2: String = If trig_HDL_Ratio_raised then trig_HDL_ratio_asChar.concat('. Levels above 2 are significant.')
        else '' endif
     Let trig_HDL_ratio_comment: String = trig_HDL_ratio_comment1.concat(trig_HDL_ratio_comment2)
     Let comment: String = bmiString.concat(bmi_AsString).concat(additionalBMIComment).concat(trig_HDL_ratio_comment)


Produce the result:

     -- result 
Let result_comment:ST = ST{value=comment}
Let result:Sequence(Observation)
= Sequence{Observation{
value = result_comment,
observationCode = commentCode
}
}
result


jsdgfuuwf