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

undocumented code objects #8

Closed
goldingn opened this issue Aug 31, 2018 · 4 comments
Closed

undocumented code objects #8

goldingn opened this issue Aug 31, 2018 · 4 comments
Assignees

Comments

@goldingn
Copy link

R CMD check flagged some exported functions that are not documented:

‘customPredictFunGBM’ ‘customPredictFunKSVM’ ‘customPredictFunLogreg’ ‘customPredictFunMultinom’ ‘customPredictFunNB’ ‘customPredictFunXGB’

perhaps these were exported by mistake?

@goldingn
Copy link
Author

there were few other issues flagged by these checks (so it might be worth running those), but that was the only one I'm particularly concerned about for the JOSS review.

@boyanangelov boyanangelov self-assigned this Aug 31, 2018
@boyanangelov
Copy link
Owner

Those functions are used to enable dismo to use mlr predictions. They are not going to be used directly by the user. Do you know if there is a better way to include them in the package?

I just ran the checks as well, did not see anything else which should be fixed there.

@goldingn
Copy link
Author

Ah, I see now that you are currently exporting every function in your package: https://github.com/boyanangelov/sdmbench/blob/master/NAMESPACE#L1

You can instead explicitly export the functions that you expect the user to interact with. You could add them individually to NAMESPACE with e.g. export(function), but it's normally easier to have roxygen auto-generate your NAMESPACE based on @export tags in the documentation for the functions you want to export. Your importFrom NAMESPACE lines can be generated from roxygen too, using @importFrom tags

@boyanangelov
Copy link
Owner

Thanks for the advice @goldingn! I just pushed the changes, now everything is generated by roxygen.

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

2 participants