epiverse-trace / linelist

R package for handling linelist data
https://epiverse-trace.github.io/linelist/
Other
8 stars 4 forks source link

Replace for loops by functional equivalents #105

Closed Bisaloo closed 8 months ago

Bisaloo commented 8 months ago

Raised by @chartgerink in #103.

We have a couple of for loops in the codebase:

https://github.com/epiverse-trace/linelist/blob/229eb0a743e737e13280c7df5020344913c3e0d6/R/validate_types.R#L44

https://github.com/epiverse-trace/linelist/blob/229eb0a743e737e13280c7df5020344913c3e0d6/R/set_tags.R#L68

and should get rid of them to comply with our own recommendation.

This overlaps with #88 as it will remove the need for a loop entirely in:

https://github.com/epiverse-trace/linelist/blob/229eb0a743e737e13280c7df5020344913c3e0d6/R/set_tags.R#L68-L73

Bisaloo commented 8 months ago

Fixed by #106 and #110.