--- type: "fhir-fhirpath-function" title: "FHIR FHIRPath Function: memberOf" source: "source/fhirpath.html" --- # FHIR FHIRPath Function: memberOf This page is part of **FHIR FHIRPath** (FHIR-specific extensions). Base spec lives at [FHIRPath](/fhirpath). `memberOf(valueset : string) : Boolean` When invoked on a single code-valued element, returns true if the code is a member of the given `valueset`. When invoked on a single concept-valued element, returns true if any code in the concept is a member of the given valueset. When invoked on a single string, returns true if the string is equal to a code in the valueset, so long as the valueset only contains one codesystem. If the valueset in this case contains more than one codesystem, the return value is empty. If the valueset cannot be resolved as a uri to a value set, or the input is empty or has more than one value, the return value is empty. Note that implementations are encouraged to make use of a terminology service to provide this functionality. For example: Observation.component.where(code.memberOf('http://hl7.org/fhir/ValueSet/observation-vitalsignresult')) This expression returns components that have a code that is a member of the observation-vitalsignresult valueset. * * * [Back to FHIR FHIRPath](/fhir-fhirpath)