Science Score: 36.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
○Academic publication links
-
✓Committers with academic emails
1 of 10 committers (10.0%) from academic institutions -
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (14.3%) to scientific vocabulary
Keywords from Contributors
tidy-data
setup
unit-testing
parsing
fwf
csv
s3-vectors
string-interpolation
tidyverse
documentation-tool
Last synced: 10 months ago
·
JSON representation
Repository
Common generic methods
Basic Info
- Host: GitHub
- Owner: r-lib
- License: other
- Language: R
- Default Branch: main
- Homepage: https://generics.r-lib.org/
- Size: 2.75 MB
Statistics
- Stars: 61
- Watchers: 4
- Forks: 13
- Open Issues: 9
- Releases: 5
Created about 8 years ago
· Last pushed about 1 year ago
Metadata Files
Readme
Changelog
License
Code of conduct
README.Rmd
---
output: github_document
---
```{r setup, include = FALSE}
knitr::opts_chunk$set(collapse = TRUE, comment = "#>")
```
# generics
[](https://github.com/r-lib/generics/actions/workflows/R-CMD-check.yaml)
[](https://app.codecov.io/gh/r-lib/generics?branch=main)
`generics` is designed to help package authors reduce dependencies by providing a set of generic methods that can be imported. For example, if a package author wanted to include a `tidy` method for their object, they would have to import the `broom` package to do so. This would work but would potentially increase the number of package dependencies required to install and/or test the package.
## Installation
To install `generics` from CRAN, use:
```{r, eval = FALSE}
install.packages("generics")
```
To install the development version, use:
```{r, eval = FALSE}
# install.packages("pak")
pak::pak("r-lib/generics")
```
## Usage
`generics` is a simple, lightweight package that contains S3 generics to be used by other packages. Some examples are:
```{r}
library(generics)
fit
tidy
```
To use `generics` with your package, we recommend that you import and re-export the generic(s) of interest. For example, if you want to provide a method for the S3 `explain()` method, you'd using the following `roxygen2` code:
``` {r, eval = FALSE}
#' @importFrom generics explain
#' @export
generics::explain
```
As an example, the [recipes](https://github.com/tidymodels/recipes) package defines a number of `tidy()` S3 methods by importing this package (whereas it previously depended on `broom`).
## Documentation
When searching for help on a method that is exported from `generics` by one or more packages, using `?method` will show entries for all exported methods. If the version from `generics` is selected, the Methods section dynamically lists all specific methods exported by any loaded packages.
Owner
- Name: R infrastructure
- Login: r-lib
- Kind: organization
- Repositories: 154
- Profile: https://github.com/r-lib
GitHub Events
Total
- Create event: 1
- Release event: 1
- Issues event: 3
- Issue comment event: 1
- Push event: 6
Last Year
- Create event: 1
- Release event: 1
- Issues event: 3
- Issue comment event: 1
- Push event: 6
Committers
Last synced: 12 months ago
Top Committers
| Name | Commits | |
|---|---|---|
| DavisVaughan | d****s@r****m | 53 |
| topepo | m****n@g****m | 51 |
| Hadley Wickham | h****m@g****m | 40 |
| Mitchell | m****d@m****u | 7 |
| Hannah Frick | h****h@r****m | 5 |
| alex hayes | a****s@g****m | 3 |
| Mara Averick | m****k@g****m | 2 |
| Jim Hester | j****r@g****m | 1 |
| Ivan Svetunkov | i****v@g****m | 1 |
| Daniel Possenriede | p****e@g****m | 1 |
Committer Domains (Top 20 + Academic)
rstudio.com: 2
monash.edu: 1
Issues and Pull Requests
Last synced: 10 months ago
All Time
- Total issues: 45
- Total pull requests: 35
- Average time to close issues: 5 months
- Average time to close pull requests: 16 days
- Total issue authors: 24
- Total pull request authors: 10
- Average comments per issue: 1.42
- Average comments per pull request: 0.89
- Merged pull requests: 32
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 3
- Pull requests: 0
- Average time to close issues: 10 days
- Average time to close pull requests: N/A
- Issue authors: 3
- Pull request authors: 0
- Average comments per issue: 0.33
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- hadley (13)
- DavisVaughan (8)
- alexpghayes (2)
- mitchelloharawild (2)
- krivit (1)
- joethorley (1)
- juliasilge (1)
- hs3434 (1)
- egnha (1)
- hfrick (1)
- topepo (1)
- oij11 (1)
- vspinu (1)
- jonocarroll (1)
- RoelVerbelen (1)
Pull Request Authors
- DavisVaughan (12)
- topepo (8)
- mitchelloharawild (3)
- hfrick (3)
- alexpghayes (2)
- joethorley (2)
- batpigandme (1)
- hadley (1)
- dpprdan (1)
- config-i1 (1)
Top Labels
Issue Labels
feature (4)
documentation (2)
upkeep (1)
Pull Request Labels
Packages
- Total packages: 2
-
Total downloads:
- cran 829,796 last-month
- Total docker downloads: 121,597,379
-
Total dependent packages: 199
(may contain duplicates) -
Total dependent repositories: 331
(may contain duplicates) - Total versions: 12
- Total maintainers: 1
cran.r-project.org: generics
Common S3 Generics not Provided by Base R Methods Related to Model Fitting
- Homepage: https://generics.r-lib.org
- Documentation: http://cran.r-project.org/web/packages/generics/generics.pdf
- License: MIT + file LICENSE
-
Latest release: 0.1.4
published about 1 year ago
Rankings
Downloads: 0.2%
Dependent packages count: 0.7%
Dependent repos count: 0.9%
Average: 5.1%
Forks count: 5.6%
Stargazers count: 5.9%
Docker downloads count: 17.3%
Maintainers (1)
Last synced:
11 months ago
conda-forge.org: r-generics
- Homepage: https://github.com/r-lib/generics
- License: MIT
-
Latest release: 0.1.3
published almost 4 years ago
Rankings
Dependent packages count: 1.6%
Dependent repos count: 5.3%
Average: 21.7%
Stargazers count: 38.1%
Forks count: 41.8%
Last synced:
11 months ago
Dependencies
.github/workflows/R-CMD-check.yaml
actions
- actions/checkout v3 composite
- r-lib/actions/check-r-package v2 composite
- r-lib/actions/setup-pandoc v2 composite
- r-lib/actions/setup-r v2 composite
- r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/pkgdown.yaml
actions
- JamesIves/github-pages-deploy-action v4.4.1 composite
- actions/checkout v3 composite
- r-lib/actions/setup-pandoc v2 composite
- r-lib/actions/setup-r v2 composite
- r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/pr-commands.yaml
actions
- actions/checkout v3 composite
- r-lib/actions/pr-fetch v2 composite
- r-lib/actions/pr-push v2 composite
- r-lib/actions/setup-r v2 composite
- r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/test-coverage.yaml
actions
- actions/checkout v3 composite
- actions/upload-artifact v3 composite
- r-lib/actions/setup-r v2 composite
- r-lib/actions/setup-r-dependencies v2 composite
DESCRIPTION
cran
- R >= 3.6 depends
- methods * imports
- covr * suggests
- pkgload * suggests
- testthat >= 3.0.0 suggests
- tibble * suggests
- withr * suggests
tests/testthat/testGenericsExtension/DESCRIPTION
cran
- generics * imports
tests/testthat/testMultiMethod/DESCRIPTION
cran
tests/testthat/testMultiPackage/DESCRIPTION
cran
tests/testthat/testS4Docs/DESCRIPTION
cran
tests/testthat/testSameRd/DESCRIPTION
cran
tests/testthat/testSingleMethod/DESCRIPTION
cran