bumbl

R package for modeling bumblebee colony growth.

https://github.com/aariq/bumbl

Science Score: 77.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 5 DOI reference(s) in README
  • Academic publication links
    Links to: zenodo.org
  • Committers with academic emails
    1 of 3 committers (33.3%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (19.0%) to scientific vocabulary

Keywords

bumblebee demography glm switchpoint
Last synced: 6 months ago · JSON representation ·

Repository

R package for modeling bumblebee colony growth.

Basic Info
  • Host: GitHub
  • Owner: Aariq
  • License: other
  • Language: R
  • Default Branch: master
  • Homepage:
  • Size: 1.63 MB
Statistics
  • Stars: 3
  • Watchers: 1
  • Forks: 2
  • Open Issues: 5
  • Releases: 8
Topics
bumblebee demography glm switchpoint
Created over 6 years ago · Last pushed 7 months ago
Metadata Files
Readme Changelog Contributing License Code of conduct Citation

README.Rmd

---
output: github_document
---



```{r, include = FALSE}
knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "man/figures/README-",
  out.width = "100%"
)
```

# Tools for modeling bumblebee colony growth



[![R-CMD-check](https://github.com/Aariq/bumbl/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/Aariq/bumbl/actions/workflows/R-CMD-check.yaml)
[![Codecov test coverage](https://codecov.io/gh/Aariq/bumbl/graph/badge.svg)](https://app.codecov.io/gh/Aariq/bumbl)
[![Project Status: Inactive – The project has reached a stable, usable state but is no longer being actively developed; support/maintenance will be provided as time allows.](https://www.repostatus.org/badges/latest/inactive.svg)](https://www.repostatus.org/#inactive)
[![CRAN status](https://www.r-pkg.org/badges/version/bumbl)](https://CRAN.R-project.org/package=bumbl)
[![metacran downloads](https://cranlogs.r-pkg.org/badges/grand-total/bumbl)](https://cran.r-project.org/package=bumbl)
[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.4545782.svg)](https://doi.org/10.5281/zenodo.4545782) 




`bumbl` implements a model for bumblebee colony growth described in Crone and Williams 2016^1^.
It models colony growth as having a switchpoint at some time, *tau*, where the colony switches from growth and worker production to gyne production and decline.
Currently `bumbl()` works by fitting a separate switchpoint model to each colony, optimizing the switchpoint, *tau*.
It returns the optimal switchpoint, growth, and decline rates for each colony.
Because the current version of `bumbl()` works by fitting a separate GLM to each colony, if covariates are included, their estimates could vary significantly among colonies.
Stay tuned for future developments that may allow estimating a single value of a covariate but different values of growth and decline rates and *tau* for each colony.

## Contributing

I'm looking for collaborators who know (or are willing to let me teach them) how to use git and GitHub and who have an interest in taking over as maintainer of this package.
I'm not a bumblebee biologist, so I would especially love a collaborator who works on bumblebees or other organisms with a similar growth, switch, decline lifecycle.

I also welcome contributions including bug-fixes, improvement of documentation, additional features, or new functions relating to bumblebee ecology and demography from anyone!

### Roadmap

-   [x] Write `bumbl()` function to model colony growth with switchpoint
-   [x] Finish documentation and vignette(s)
-   [x] [rOpenSci review]()
-   [x] Regroup with Elizabeth Crone to discuss current behavior of `bumbl()`
-   [x] Release v0.1.0 and archive on Zenodo
-   [x] Bug fixes
-   [x] Submit v1.0.0 of package to CRAN
-   [x] Write a manuscript for JOSS ([desk-reject](https://github.com/openjournals/joss-reviews/issues/3532), out of scope)
-   [x] Release minor version to CRAN to update citation
-   [ ] Possibly re-work internals of `bumbl()`? (see [\#58](https://github.com/Aariq/bumbl/issues/58) and [notes](https://github.com/Aariq/bumbl/blob/master/notes/single-model-rework-notes.Rmd))
-   [ ] Submit v2.0.0 of package to CRAN

Other possible areas of improvement:

-   Extend `bumbl()` to work with GLMMs
-   Test significance of switchpoint (see [\#62](https://github.com/Aariq/bumbl/issues/62))
-   Extend `bumbl()` to work with dates, datetimes, or other timeseries classes (see [\#46](https://github.com/Aariq/bumbl/issues/46))

## Installation

You can install `bumbl` with:

``` r
install.packages("bumbl")
```

Or install the development version with:

``` r
devtools::install_github("Aariq/bumbl", build_vignettes = TRUE)
```

## Getting started

View the package vignette with:

``` r
library(bumbl)
vignette("bumbl")
```

```{r include=FALSE}
# library(bumbl)
devtools::load_all()
```

View the `bomubs` dataset

```{r}
head(bombus)
```

### Example use

Using a subset of the `bombus` dataframe to estimate the week (tau) that colonies switch to reproduction

```{r}
bombus2 <- bombus[bombus$colony %in% c(9, 82, 98, 35), ]
results <- bumbl(bombus2, colonyID = colony, t = week, formula = d.mass ~ week)
results
```

Plot the results

```{r}
par(mfrow = c(2, 2))
plot(results)
par(mfrow = c(1, 1))
```

# References

^1^Crone, E.
E., and Williams, N. M.
(2016).
Bumble bee colony dynamics: quantifying the importance of land use and floral resources for colony growth and queen production.
Ecol.
Lett.
19, 460–468.


------------------------------------------------------------------------

Please note that the `bumbl` project is released with a [Contributor Code of Conduct](https://github.com/Aariq/bumbl/blob/master/CODE_OF_CONDUCT.md).
By contributing to this project you agree to abide by its terms.

Owner

  • Name: Eric R. Scott
  • Login: Aariq
  • Kind: user
  • Company: University of Arizona, @cct-datascience

Scientific Programmer & Educator at University of Arizona

Citation (CITATION.cff)

# -----------------------------------------------------------
# CITATION file created with {cffr} R package, v0.4.1
# See also: https://docs.ropensci.org/cffr/
# -----------------------------------------------------------

cff-version: 1.2.0
message: 'To cite package "bumbl" in publications use:'
type: software
license: CC-BY-4.0
title: 'bumbl: Tools for Modeling Bumblebee Colony Growth and Decline'
version: 1.0.4
doi: 10.5281/zenodo.4545782
abstract: Bumblebee colonies grow during worker production, then decline after switching
  to production of reproductive individuals (drones and gynes). This package provides
  tools for modeling and visualizing this pattern by identifying a switchpoint with
  a growth rate before and a decline rate after the switchpoint. The mathematical
  models fit by bumbl are described in Crone and Williams (2016) <doi:10.1111/ele.12581>.
authors:
- family-names: Scott
  given-names: Eric R.
  email: scottericr@gmail.com
  orcid: https://orcid.org/0000-0002-7430-7879
preferred-citation:
  type: generic
  title: 'bumbl: Tools for modeling bumblebee colony growth and decline'
  authors:
  - family-names: Scott
    given-names: Eric R.
    email: scottericr@gmail.com
    orcid: https://orcid.org/0000-0002-7430-7879
  year: '2021'
  publisher:
    name: Zenodo
  version: 1.0.4
  doi: 10.5281/zenodo.4545782
  url: https://doi.org/10.5281/zenodo.4545782
repository: https://CRAN.R-project.org/package=bumbl
repository-code: https://github.com/Aariq/bumbl
url: https://github.com/Aariq/bumbl
contact:
- family-names: Scott
  given-names: Eric R.
  email: scottericr@gmail.com
  orcid: https://orcid.org/0000-0002-7430-7879
keywords:
- bumblebee
- demography
- glm
- switchpoint
references:
- type: article
  title: 'Bumble bee colony dynamics: quantifying the importance of land use and floral
    resources for colony growth and queen production'
  authors:
  - family-names: Crone
    given-names: Elizabeth E.
    email: elizabeth.crone@tufts.edu
  - family-names: Williams
    given-names: Neal M.
  journal: Ecology Letters
  year: '2016'
  volume: '19'
  issue: '4'
  doi: 10.1111/ele.12581
  start: 460-468

GitHub Events

Total
  • Issues event: 1
  • Delete event: 1
  • Push event: 4
  • Pull request event: 1
  • Create event: 1
Last Year
  • Issues event: 1
  • Delete event: 1
  • Push event: 4
  • Pull request event: 1
  • Create event: 1

Committers

Last synced: about 2 years ago

All Time
  • Total Commits: 286
  • Total Committers: 3
  • Avg Commits per committer: 95.333
  • Development Distribution Score (DDS): 0.007
Past Year
  • Commits: 20
  • Committers: 2
  • Avg Commits per committer: 10.0
  • Development Distribution Score (DDS): 0.05
Top Committers
Name Email Commits
Aariq s****r@g****m 284
Hadley Wickham h****m@g****m 1
Rebecca Killick r****k@l****k 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 54
  • Total pull requests: 18
  • Average time to close issues: 3 months
  • Average time to close pull requests: 4 days
  • Total issue authors: 2
  • Total pull request authors: 3
  • Average comments per issue: 1.06
  • Average comments per pull request: 0.22
  • Merged pull requests: 18
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • Aariq (54)
  • jhemberger (1)
Pull Request Authors
  • Aariq (17)
  • rkillick (1)
  • hadley (1)
Top Labels
Issue Labels
enhancement (19) bug (12) Priority: Low (9) Priority: Medium (9) Priority: High (9) documentation (9) question (4) needs testing (3) questioning (2) help wanted (1)
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • cran 384 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 0
  • Total versions: 5
  • Total maintainers: 1
cran.r-project.org: bumbl

Tools for Modeling Bumblebee Colony Growth and Decline

  • Versions: 5
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 384 Last month
Rankings
Forks count: 14.9%
Stargazers count: 26.2%
Average: 27.1%
Downloads: 29.0%
Dependent packages count: 29.8%
Dependent repos count: 35.5%
Maintainers (1)
Last synced: 6 months ago

Dependencies

DESCRIPTION cran
  • R >= 3.0 depends
  • MASS * imports
  • broom * imports
  • dplyr * imports
  • ggplot2 * imports
  • glue * imports
  • purrr * imports
  • rlang * imports
  • tidyr >= 1.0.0 imports
  • car * suggests
  • covr * suggests
  • knitr * suggests
  • rmarkdown * suggests
  • rsq * suggests
  • testthat >= 2.1.0 suggests
.github/workflows/R-CMD-check.yaml actions
  • actions/cache v3 composite
  • actions/checkout v3 composite
  • actions/upload-artifact v3 composite
  • r-lib/actions/setup-pandoc v2 composite
  • r-lib/actions/setup-r v2 composite
.github/workflows/knit-paper.yaml actions
  • actions/checkout v3 composite
  • actions/upload-artifact v3 composite
  • openjournals/openjournals-draft-action master composite
.github/workflows/test-coverage.yaml actions
  • actions/checkout v3 composite
  • r-lib/actions/setup-r v2 composite