datasets_selfmade: Toy example bundles for multiple entries

example_bundles1R Documentation

Toy example bundles for multiple entries

Description

These data examples are bundles that contain very few, very simple resources that have multiple entries and can be used for demonstration purposes. See Source for how the xml versions look.

Usage

example_bundles1

example_bundles2

example_bundles3

example_bundles4

example_bundles5

example_bundles6

example_bundles7

example_bundles_empty

Format

An object of class fhir_bundle_list of length 1.

An object of class fhir_bundle_list of length 1.

An object of class fhir_bundle_list of length 1.

An object of class fhir_bundle_list of length 1.

An object of class fhir_bundle_list of length 1.

An object of class fhir_bundle_list of length 1.

An object of class fhir_bundle_list of length 1.

An object of class fhir_bundle_list of length 1.

Details

example_bundles1 contains 1 bundle with 2 Patient resources.

example_bundles2 contains 1 bundle with 3 Patient resources.

example_bundles3 contains 1 bundle with 3 Patient resources and 1 Observation resource.

example_bundles4 contains 1 bundle with 2 Medication resources, one of which has some ⁠@id⁠ xml attributes

example_bundles5 contains 1 bundle with 2 Observation resources.

example_bundles6 contains 1 bundle with 2 Patient resources.

example_bundles7 contains 1 bundle with 2 Patient resources.

example_bundles_empty contains one empty bundle.

Source

example_bundles1

<Bundle>
 <type value='searchset'/>
 <entry>
  <resource>
    <Patient>
       <id value='id1'/>
	      <address>
	         <use value='home'/>
	         <city value='Amsterdam'/>
	         <type value='physical'/>
	         <country value='Netherlands'/>
	      </address>
	      <name>
	         <given value='Marie'/>
	      </name>
    </Patient>
  </resource>
 </entry>

 <entry>
  <resource>
    <Patient>
       <id value='id3'/>
	      <address>
	         <use value='home'/>
	         <city value='Berlin'/>
	      </address>
       <address>
          <type value='postal'/>
          <country value='France'/>
       </address>
	      <address>
	         <use value='work'/>
	         <city value='London'/>
	         <type value='postal'/>
	         <country value='England'/>
	      </address>
       <name>
          <given value='Frank'/>
       </name>
       <name>
          <given value='Max'/>
       </name>
    </Patient>
  </resource>
 </entry>
</Bundle>

example_bundles2

<Bundle>
 <type value='searchset'/>
 <entry>
  <resource>
     <Patient>
        <id value='id1'/>
        <address>
           <use value='home'/>
           <city value='Amsterdam'/>
           <type value='physical'/>
           <country value='Netherlands'/>
        </address>
        <name>
           <given value='Marie'/>
        </name>
     </Patient>
   </resource>
 </entry>

 <entry>
  <resource>
    <Patient>
        <id value='id2'/>
        <address>
           <use value='home'/>
           <city value='Rome'/>
           <type value='physical'/>
           <country value='Italy'/>
        </address>
        <address>
           <use value='work'/>
           <city value='Stockholm'/>
	          <type value='postal'/>
           <country value='Sweden'/>
        </address>
        <name>
           <given value='Susie'/>
       </name>
    </Patient>
  </resource>
 </entry>

 <entry>
  <resource>
    <Patient>
       <id value='id3'/>
       <address>
          <use value='home'/>
          <city value='Berlin'/>
       </address>
       <address>
          <type value='postal'/>
          <country value='France'/>
       </address>
       <address>
          <use value='work'/>
          <city value='London'/>
          <type value='postal'/>
          <country value='England'/>
       </address>
       <name>
          <given value='Frank'/>
      </name>
      <name>
          <given value='Max'/>
       </name>
    </Patient>
  </resource>
 </entry>
</Bundle>

example_bundles3

<Bundle>
 <type value='searchset'/>
 <entry>
  <resource>
    <Patient>
       <id value='id1'/>
       <address>
          <use value='home'/>
          <city value='Amsterdam'/>
          <type value='physical'/>
          <country value='Netherlands'/>
       </address>
       <name>
          <given value='Marie'/>
       </name>
    </Patient>
  </resource>
 </entry>

 <entry>
  <resource>
    <Patient>
       <id value='id2'/>
       <address>
          <use value='home'/>
          <city value='Rome'/>
          <type value='physical'/>
          <country value='Italy'/>
       </address>
       <address>
          <use value='work'/>
          <city value='Stockholm'/>
          <type value='postal'/>
          <country value='Sweden'/>
       </address>
       <name>
          <given value='Susie'/>
       </name>
    </Patient>
  </resource>
 </entry>

 <entry>
  <resource>
    <Patient>
       <id value='id3'/>
       <address>
          <use value='home'/>
          <city value='Berlin'/>
       </address>
       <address>
          <type value='postal'/>
          <country value='France'/>
       </address>
       <address>
          <use value='work'/>
          <city value='London'/>
          <type value='postal'/>
          <country value='England'/>
       </address>
       <name>
          <given value='Frank'/>
       </name>
       <name>
          <given value='Max'/>
       </name>
    </Patient>
  <resource/>
 </entry>

 <entry>
  <resource>
    <Observation>
       <id value = 'obs1'/>
       <code>
          <coding>
             <system value='http://loinc.org'/>
             <code value='29463-7'/>
             <display value='Body Weight'/>
          </coding>
          <coding>
             <system value='http://snomed.info/sct'/>
             <code value='27113001'/>
             <display value='Body weight'/>
          </coding>
       </code>
       <subject>
          <reference value='Patient/id3'/>
       </subject>
    </Observation>
  </resource>
 </entry>
</Bundle>"

example_bundles4

<Bundle>
    <type value='searchset'/>
 <entry>
	 <resource>
		<Medication>
		    <id value='1285'/>
		    <code>
		        <coding>
		            <system value='http://www.nlm.nih.gov/research/umls/rxnorm'/>
		            <code value='1594660'/>
		            <display value='Alemtuzumab 10mg/ml (Lemtrada)'/>
		        </coding>
		    </code>
		    <ingredient id='1'>
		    	<itemReference>
	        		<reference value='Substance/5463'/>
	    		</itemReference>
		    </ingredient>
		    <ingredient id='2'>
		    	<itemReference>
	        		<reference value='Substance/3401'/>
	    		</itemReference>
		    </ingredient>
		</Medication>
	</resource>
 </entry>

 <entry>
	 <resource>
         <Medication>
             <id value='45226'/>
             <code>
                 <coding>
                     <system value='http://snomed.info/sct'/>
                     <code value='373994007'/>
                     <display value='Prednisone 5mg tablet (Product)'/>
                 </coding>
                 <text value='Prednisone 5mg tablet (Product)'/>
             </code>
		    <ingredient id='1'>
		    	<itemReference>
	        		<reference value='Substance/6912'/>
	    		</itemReference>
		    </ingredient>
		    <ingredient id='2'>
		    	<itemReference>
	        		<reference value='Substance/3710'/>
	    		</itemReference>
		    </ingredient>
		</Medication>
	</resource>
 </entry>

</Bundle>

example_bundles5

<Bundle>
 <type value='searchset'/>
 <entry>
  <resource>
    <Observation>
       <id value = 'obs1'/>
       <code>
          <coding>
             <system value='http://loinc.org'/>
             <code value='29463-7'/>
             <display value='Body Weight'/>
          </coding>
          <coding>
             <system value='http://snomed.info/sct'/>
             <code value='27113001'/>
             <display value='Body weight'/>
          </coding>
       </code>
       <subject>
          <reference value='Patient/id3'/>
       </subject>
    </Observation>
  </resource>
 </entry>

 <entry>
  <resource>
    <Observation>
       <id value = 'obs2'/>
       <code>
          <coding>
             <system value='http://loinc.org'/>
             <code value='8302-2'/>
             <display value='Body Height'/>
          </coding>
          <coding>
             <system value='http://snomed.info/sct'/>
             <code value='50373000'/>
             <display value='Body height measure'/>
          </coding>
       </code>
       <subject>
          <reference value='Patient/id3'/>
       </subject>
    </Observation>
  </resource>
 </entry>
</Bundle>"

example_bundles6

"<Bundle>
    <type value='searchset'/>
    <entry>
   	<resource>
		<Patient>
			<id value='id1'/>
			<address>
				<line value='Example Street 1'/>
				<line value='c/o Baker'/>
				<city value = 'London'/>
				<use value = 'home'/>
			</address>
			<address>
				<line value = 'Some firm'/>
				<line value = 'Some Department'/>
				<line value = 'Some Lane 1'/>
				<city value = 'London'/>
				<use value = 'work'/>
			</address>
		</Patient>
	 </resource>
  </entry>
  <entry>
	<resource>
		<Patient>
			<id value='id2'/>
			<address>
				<line value='Rue example 3'/>
				<city value = 'Paris'/>
				<use value = 'home'/>
			</address>
			<address>
				<line value = 'La fabrique'/>
				<line value = 'Avenue 33'/>
				<city value = 'Paris'/>
				<use value = 'work'/>
			</address>
		</Patient>
	</resource>
  </entry>
</Bundle>"

example_bundles7

"<Bundle>
    <type value='searchset'/>
    <entry>
   	<resource>
		<Patient>
			<id value='id1'/>
			<name>
				<given value='Marie'/>
				<given value='Luise'/>
				<family value = 'Smith'/>
				<use value = 'official'/>
			</name>
			<name>
				<given value = 'Lea'/>
				<given value = 'Sophie'/>
				<given value = 'Anna'/>
				<family value = 'Baker'/>
				<use value = 'nickname'/>
			</name>
		</Patient>
	 </resource>
  </entry>
  <entry>
	<resource>
		<Patient>
			<id value='id2'/>
			<name>
				<given value='Max'/>
				<family value = 'Brown'/>
				<use value = 'official'/>
			</name>
			<name>
				<given value = 'Anton'/>
				<given value = 'John'/>
				<family value = 'Jones'/>
				<use value = 'nickname'/>
			</name>
		</Patient>
	</resource>
  </entry>
</Bundle>"

example_bundles_empty

<Bundle>
    <id value="c9edcd82-092c-4f63-8c8d-fdfd03e38d64"/>
    <meta>
        <versionId value="23558aa5-aeba-4145-89a3-195bb6ec5401"/>
        <lastUpdated value="2024-11-19T13:43:34.556+00:00"/>
    </meta>
    <type value="searchset"/>
    <timestamp value="2024-11-19T13:43:34.556+00:00"/>
    <total value="0"/>
    <link>
        <relation value="self"/>
        <url value="https://server.fire.ly/Patient?gender=bla&amp;_total=accurate&amp;_count=0&amp;_skip=0"/>
    </link>
</Bundle>

Examples

#unserialize xml objects before doing anything else with them!
fhir_unserialize(bundles = example_bundles1)
#unserialize xml objects before doing anything else with them!
fhir_unserialize(bundles = example_bundles2)
#unserialize xml objects before doing anything else with them!
fhir_unserialize(bundles = example_bundles3)
#unserialize xml objects before doing anything else with them!
fhir_unserialize(bundles = example_bundles4)
#unserialize xml objects before doing anything else with them!
fhir_unserialize(bundles = example_bundles5)
#unserialize xml objects before doing anything else with them!
fhir_unserialize(bundles = example_bundles6)
#unserialize xml objects before doing anything else with them!
fhir_unserialize(bundles = example_bundles7)
#unserialize xml objects before doing anything else with them!
fhir_unserialize(bundles = example_bundles_empty)

POLAR-fhiR/fhircrackr documentation built on Dec. 24, 2024, 3:06 a.m.