alan-turing-institute / eider

eider: an R package for processing health records declaratively
https://alan-turing-institute.github.io/eider/
Other
2 stars 0 forks source link

New features #61

Closed yongrenjie closed 7 months ago

yongrenjie commented 7 months ago

Renaming stuff


New featurisers


Other usability things


Input validation

yongrenjie commented 7 months ago

@helendduncan I'm so sorry this is a bit of a mammoth PR. I should definitely have put stuff in one at a time. I did try to explain the changes in the comment and I suppose we have chatted about this... But still I recognise the code review is ugly 😓

let me know if you want to go through this together at any point in time.

By far the most important code changes are R/featurise_lookup.R, R/featurise_present.R, and R/validation.R, the rest are mostly tweaks just to fix function signatures or stuff like that

helendduncan commented 7 months ago

Hi @yongrenjie - I'm going to make a few comments here just to make sure that I understand everything - not because I think there's anything missing from the code, but when I merge in the vignettes and docs stuff I want to make sure I understand what's happening. So sorry if you get a million messages - they don't mean anything bad!! :P

helendduncan commented 7 months ago

@yongrenjie I really like the all_ids #59 option and it's utility to add users who aren't present (like in the test case) what do you think about putting a trace message in there about either (some/list) IDs not present in original table or a more generic statement which states that the original IDs may not have been present in the initial data?

helendduncan commented 7 months ago

validate.R will throw error messages when there is discrepancy between the types of filter value in the spec, and the specified column in the data. It will also throw an error if the 'absent_default_value' is not an integer - where the error also notes its optional nature. However there is no trace or debug error about if one isn't provided that a default would be used - should this be added in?

helendduncan commented 7 months ago

Having discussed this with you I agree it's a good idea to make new issues of the comments and merge this wonderful PR

yongrenjie commented 7 months ago

opened new issues #72 and #73, I'll take care of them!