Skip to content
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

Add subroutines and reduce code duplication [sub-daily CDM lite] #7

Closed
rjhd2 opened this issue Jan 28, 2022 · 2 comments · Fixed by #23
Closed

Add subroutines and reduce code duplication [sub-daily CDM lite] #7

rjhd2 opened this issue Jan 28, 2022 · 2 comments · Fixed by #23
Assignees

Comments

@rjhd2
Copy link
Contributor

rjhd2 commented Jan 28, 2022

Lots of duplicated code. Handle each variable in a separate subroutine, and then pull out identical code snippets where possible into further subroutines.

Preparation for using look-up dictionaries etc for some of the conversions.

@rjhd2 rjhd2 self-assigned this Jan 28, 2022
@rjhd2
Copy link
Contributor Author

rjhd2 commented Feb 18, 2022

Next bit is the QC tables codes, and then another go through to find any last bits that could be combined.

rjhd2 added a commit that referenced this issue Feb 21, 2022
@rjhd2 rjhd2 changed the title Add subroutines and reduce code duplication Add subroutines and reduce code duplication [sub-daily CDM lite] Feb 21, 2022
@rjhd2
Copy link
Contributor Author

rjhd2 commented Feb 21, 2022

Have added a number of functions to process the dataframes. Much shorter code. Futher shortening could be done by using a loop across all variables, but this has not been done so far - in order to keep legibility for the coders. Will be addressed in #22

@rjhd2 rjhd2 closed this as completed in #23 Feb 21, 2022
rjhd2 added a commit that referenced this issue Feb 21, 2022
* #7: started combining code into some subroutines

* #7: qc frame created in subroutine and fixed bug on column concatenations

* #7: lots of minor formatting changes

* #7: standardised column lists and one further shortening

* #7: added qc-test dictionary to spin through
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant