New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft attempt at ingestion using mapping file #24
base: main
Are you sure you want to change the base?
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
- Reads data into class then back out again, probably not very efficient. - Not tested with multiple rows of input data - Can't cope with multiple columns trying to set the same variable (need logic in mapping file for this)
a9f8a4b
to
b7f0848
Compare
Backbone elements converted to full FHIR to be written out as *_dense. Add ID to Encounter resource
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Few minor typos
codes = [old_dict[name + ".system"] + "|" + formatted_code] | ||
else: | ||
formatted_code = [ | ||
c if isinstance(c, str) else str(int(c)) for c in raw_codes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This assumes that leading 0s in codes are not significant - is that true? (probably, but good to make sure, and document elsewhere)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, not sure about this - I don't think I've seen codes with leading 0's but that doesn't mean they don't exist
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sadiekelly have you seen any codes starting with leading 0s?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, I haven't, none of the codes I've used so far begin with a zero. I've not been able to find anything that definitively says codes do not start with a zero, but it seems like a fair assumption to make from what we currently are using. I'll keep an eye out for any codes that do have leading zeros.
Reads data into class then back out again