FHIR Chat · How to enable/disable variables · implementers

Stream: implementers

Topic: How to enable/disable variables


view this post on Zulip Lauri Karppinen (Jan 04 2019 at 13:46):

There is a switch to enable or disable certain variables from our study view. For example if there is variables for PEF, FEV1 and FEV6 and user disables PEF it's not calculated and shown on the study view. I would like to store information about this selection somehow. Information is stored but not used in analysis. All the variables gets stored anyway but I would like to effect what is used in analysis and what's not. This is needed when information is imported back to analysis software. All variable values are stored in the different observation resources. Is there some FHIR way to do this?

view this post on Zulip Lloyd McKenzie (Jan 04 2019 at 14:46):

I guess the first question is how you would talk about what variables you're expecting to collect in general (irrespective of whether you'll include them in analysis or for display in a particular view). Typically we point to PlanDefinition for that - that's the way we define protocols in FHIR. Expectations around analysis would also be included in the protocol as one of the steps involved. The notion of what to display/not to display would probably be handled as an extension

view this post on Zulip Mikael Rinnetmäki (Jan 04 2019 at 14:53):

@Lauri Karppinen what are you actually storing as the analysis? Of course you store all the observations (independently), but in addition I imagine you could store a DiagnosticReport or another type of resource that stores the information (as references) on which observations were used in the analysis, as well as the outcome of that analysis.

view this post on Zulip Lauri Karppinen (Jan 07 2019 at 07:16):

Thanks for the answers.

@Mikael Rinnetmäki I don't actually have to save the analysis. They are calculated from the observations when they are read back. Such as average values pre and post etc... I just need to store the information about UI in software (PEF enabled/disabled, FEV1 enabled/disabled etc...).

@Lloyd McKenzie extension with valueBoolean could be something what it could be done. Can I put extensions inside component? I need to give information somehow what variable is concealed/hidden from ui and calculations. This is something I came up with:
"component": [ { "code": { "coding": [ { "code": "LP115839-5", "display": "Peak expiratory flow", "system": "http://loinc.org" }, { "code": "263721004", "display": "Concealed (qualifier value)", "system": "http://snomed.info/sct" } ], "extension": [ { "url": "http://phr.kanta.fi/StructureDefinition/fiphr-boolean", "valueBoolean": "true" } ] } }, { "code": { "coding": [ { "code": "20150-9", "display": "FEV1", "system": "http://loinc.org" }, { "code": "263721004", "display": "Concealed (qualifier value)", "system": "http://snomed.info/sct" } ], "extension": [ { "url": "http://phr.kanta.fi/StructureDefinition/fiphr-boolean", "valueBoolean": "true" } ] } }, { "code": { "coding": [ { "code": "65655-3", "display": "FEV6", "system": "http://loinc.org" }, { "code": "263721004", "display": "Concealed (qualifier value)", "system": "http://snomed.info/sct" } ], "extension": [ { "url": "http://phr.kanta.fi/StructureDefinition/fiphr-boolean", "valueBoolean": "true" } ] } }, { "code": { "coding": [ { "code": "702534005", "display": "Forced expiratory volume in one second/Forced expiratory volume in six seconds ratio", "system": "http://snomed.info/sct" }, { "code": "263721004", "display": "Concealed (qualifier value)", "system": "http://snomed.info/sct" } ], "extension": [ { "url": "http://phr.kanta.fi/StructureDefinition/fiphr-boolean", "valueBoolean": "true" } ] } } ]

I noticed that component.valueBoolean was added to v4. I even tested it and it worked great. I still don't want to add it just yet because development has been with v3 so we are going to stick with it and and add support to v4 later...
Edit:
This seems to work in http://hapi.fhir.org/baseDstu3/Observation where I have been testing my implementations. Can someone confirm or give comment does this seem the right way to do this? Thanks! :)

view this post on Zulip Lloyd McKenzie (Jan 07 2019 at 08:10):

Are you wanting to set the flag in every single Observation? Would that not typically be done at the protocol level rather than for every single result?

view this post on Zulip Lauri Karppinen (Jan 07 2019 at 08:15):

Are you wanting to set the flag in every single Observation? Would that not typically be done at the protocol level rather than for every single result?

@Lloyd McKenzie
There are several PEF measurements and several FEV1 measurements and so on. This selection enables/disables each. I'm considering writing my example to spirometry study observation which "collects" all of these in one study.

view this post on Zulip Lloyd McKenzie (Jan 07 2019 at 08:33):

So the intention is that for each measurement collected for each patient you'd go in and flag which ones should be considered vs. not?

view this post on Zulip Lauri Karppinen (Jan 07 2019 at 08:34):

So the intention is that for each measurement collected for each patient you'd go in and flag which ones should be considered vs. not?

At the moment our FHIR import/export has this kind of chain of observations: study->protocol(screening/serial monitoring)->phase(pre/post)->measurementMode->breath/topbreaths->variable/flow. So where I was planning to write this is on the very top of the "observation tree". Does this seem completely wrong way? This must not be the most usual thing to do with FHIR... but I have to figure out some way to do this.

view this post on Zulip Lloyd McKenzie (Jan 07 2019 at 08:48):

When you talk about "study" and "protocol", are you talking about a "panel" Observation instance that's used as a grouper of other observations, or are you talking about the actual study and protocol? (Because the latter would be represented as ResearchStudy and PlanDefinition.) Observation represents what was done, never what "is to be done".

view this post on Zulip Lauri Karppinen (Jan 07 2019 at 09:03):

I'm talking about observation that groups other observations together.

view this post on Zulip Lloyd McKenzie (Jan 07 2019 at 09:29):

So the decision on what data to not use is made after the results are captured, not before?

view this post on Zulip Lauri Karppinen (Jan 07 2019 at 09:32):

Yes after. All the data is captured and stored every time. This is just selection in UI what to show.

view this post on Zulip Lloyd McKenzie (Jan 07 2019 at 09:34):

Ok, then yes, the extension will work - whether at the root Observation or on components, as needed. (Though I might make the extension id a bit more intuitive :))

view this post on Zulip Lauri Karppinen (Jan 07 2019 at 09:49):

Thanks a lot for the answers @Lloyd McKenzie . It's great to have confirmation for plans before implementing :)

view this post on Zulip Lloyd McKenzie (Jan 07 2019 at 15:01):

That's what these forums are for :)


Last updated: Apr 12 2022 at 19:14 UTC