NCEAS / codyn

Community dynamics metrics
33 stars 8 forks source link

requesting rephrasing of error message for function `check_multispp` #131

Open katharinehogan opened 2 years ago

katharinehogan commented 2 years ago

Hello, First of all, thank you for doing the extra work of publicly documenting and maintaining this package. I was able to easily debug something that otherwise would have been more difficult (and appreciate the extra work regardless). I think this is the same request as the issue posted on 10/9/2015 by @laurenmh.

I would like to suggest clarifying or at least revisiting the error message returned by check_multispp. It currently returns "One or more replicates consists of only a single species; please remove these replicates prior to calculations". After debugging directly from check_multispp (rather than the synchrony function that originally threw the error), I found the issue was that one site in my replicate.var= argument column was only sampled one time. synchrony ran just fine once I removed that site.

I was initially really confused by the error message saying that one replicate had only one species. Phrasing it as # of species made me think I needed to group_by(year,site) %>% add_count(species) to see where there was only a single species, which did not solve my issue. I would like to suggest the error message be rephrased to something like "occurs only once" instead of "consists of only a single species".

In hindsight I can see the reasoning for mentioning species, and my suggestion might not be better - but overall I found the reference to species misleading, since it's not clear what exactly check_multispp is counting in the background. Thank you for reading and considering my suggestion.

mbjones commented 2 years ago

Hi @katharinehogan thank you so much for the suggestion. Just to clarify, are you suggesting the message be: "One or more replicates occurs only once; please remove these replicates prior to calculations"?

Thoughts from others on this wording? @laurenmh @itcarroll And does anyone want to create a Pull Request?

katharinehogan commented 7 months ago

Hi @mbjones sorry, I completely forgot to reply to this until here I am doing a different codyn analysis and remembering. And yes, I think that rephrasing would be more clear. Just something to switch the focus from "species" to the replicates column.

mbjones commented 7 months ago

Sounds great. We could really use some help from the community that uses codyn to maintain the package, so we welcome contributions.

katharinehogan commented 7 months ago

As someone with decent R programming knowledge but no experience creating/maintaining packages, what sorts of contributions are most useful?

mbjones commented 7 months ago

From our CONTRIBUTING.md document:

🎉

We'd also appreciate help with testing and releasing new versions of the package, and any other maintenance tasks. If you are familiar with R enough to use the package, then it's a straightforward process to contributing to maintaining the code. Sometimes it's pretty small changes, but incredibly useful to keep the package operational and valuable. And, I think anyone using the package might have some great ideas on how to extend it to make it even more useful to the community.