-
Notifications
You must be signed in to change notification settings - Fork 3
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
conventions on variables, arguments, functions, etc #163
Comments
This might be too related to #134. But my main point would be to have that in the contribution guidelines. |
Hi Bruno, So for example Regarding the model naming, there is a clear tendency for @venpopov and me to go for an additional Should you have more feedback, feel free to bring it up here. We are happy about everything that helps getting this package to an easy to use and flexible tool that as many people as possible can contribute to. |
I agree. This has bugged me for a while and a few weeks ago I changed all internals to underscore conventions, and was planning to raise an issue for the user facing functions as well. My preference would be for everything to be using underscores and lower case. sdm_simple, etc. @GidonFrischkorn thoughts? |
Posted this before seeing your comment above. Yes, I'm forr the version argument we discussed, but for everything else use that naming consistency |
I also wanted to comment briefly on the likelihood of changes. As you noted, we are in development, so some things will change, but I think we are at a stage where most of the core functionality of the package is stable. We plan to submit to CRAN in the next few months, so after that stability should be guaranteed and any breaking changes will be introduced gradually with temporary backwards compatibility. |
@GidonFrischkorn related to this, we might want to also rethink the I don't remember why we had it like this, but it's inconsistent with both |
I see your point, we could make this a |
Ok, @GidonFrischkorn here's a proposal for changes, some of which we've discussed over the last months:
This swtich to the version argument for models instead of separate functions will be a bit more work than just renaming the other arguments, but I'm pretty sure it shouldn't be much of a problem and can get this done we agree this is the way to go. |
by the way, you also have |
Fair point. When writing some vignettes, I already thought that something is weird in writing @venpopov maybe we can edit the vignettes to say |
As far as I see, these changes tap the most inconsistencies. I was thinking, if we should keep the |
alright, I'll get started on this |
All naming changes are now implemented in the latests v0.5.1 release. Thanks again @bnicenboim for bringing this up. In the next few days we'll add a section on the developer's guide (https://venpopov.github.io/bmm/dev/dev-notes/) about the naming conventions |
Hi,
As I said before, amazing idea! I'm sorry to be annoying with this (which seems not that important, but in my experience it is). But it would be good to have some wiki/contribution guidelines for how to name arguments, functions, and variables consistently. This will help (me/others) to contribute new models and to start using the existing functions without the worry that they will change (a lot, of course they'll change it's in development):
I've noticed that there are already some inconsistencies, so for example here:
IMMfull(resp_err = "dev_rad", nt_features = paste0("col_nt", 1:7), nt_distances = paste0("dist_nt",1:7), setsize = "set_size")
Shouldn't it be
set_size
? Does it make sense to cutresp_error
intoresp_err
? Also, how are models named? Given that you haveIMMfull
(why notIMM_full
?), shouldn't it beSDMsimple
(or betterSDM_simple
) rather than sdmSimple?The text was updated successfully, but these errors were encountered: