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

SG1 DBEpreparedObj function and generate generateProbs_John #53

Open
John-Ball-Cefas opened this issue Sep 17, 2020 · 1 comment
Open
Assignees

Comments

@John-Ball-Cefas
Copy link
Contributor

Hello,

I have pushed the current draft of two functions to my personnel folder in
SG1 (John). DBEpreparedObj has an oxygen skeleton, however generateProbs_John does
not as I believe Nuno may have also been working on the function and it may need to be
merged somehow.
DBEpreparedObj: takes raw objects and fills out probabilities based on generateProbs_John
and produces .rdata files of objs

generateProbs_John: fills out probabilities based on method col

Cheers,

John

@davidcurrie2001
Copy link
Collaborator

davidcurrie2001 commented Sep 18, 2020

To identify style issues with the draft package, install the lintr package and then run lintr::lint_package(linters=lintr::with_defaults(object_name_linter=lintr::object_name_linter(styles = "camelCase")))
This should identify the style issues that will be flagged when committing to the package.

The styler R package (using the tidyverse style) can be used to fix some common style problems easily (e.g. spaces after commas) - there is an RStudio add-in for this that allows you easily style a selection of code or a file. Once you do this you are left with the following issues:

  • variable and function names should be camelCase (not snake_case or PascalCase)
  • Lines shouldn't be longer than 80 characters
  • function cyclomatic complexity (I wouldn't worry about this at the moment)

I've put cleaned versions of the functions in the SG6 branch https://github.com/ices-eg/WK_RDBES/tree/SG6/WKRDB-EST2/subGroup6/icesRDBES/R

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants