ThomUK / SPCreporter

Creates Metric Reports using Statistical Process Control in the NHS style
https://thomuk.github.io/SPCreporter/
Other
6 stars 2 forks source link

Internal: rename example data directory #106

Open francisbarton opened 8 months ago

francisbarton commented 8 months ago

The R Packages book suggests example data files be stored under inst/extdata.

Some lines of code in package documentation may need to be amended in response to this.

ThomUK commented 6 months ago

Yes, agree. I'm also conflicted about the use of the example data to run tests against. I like the theory, but the practice becomes a bit unwieldy during development. I'd welcome a discussion about the pros/cons of potentially separating the two:

  1. Example data to show the package features to new users
  2. A separate group of data files to check edge cases as part of testing
francisbarton commented 6 months ago

I think you're right that the data files for testing purposes (could be complex cases and with improbable data patterns) should be different to the example Excel files for users to get started with.

I don't know what the best practice is around data sets specifically for testing - internal package data, snapshots, or just functions/explicit data creation within the test suite itself? Whatever makes development go most smoothly. But yes go ahead and separate these, it was a nice idea in a way but it's not serving us in ongoing development.