https://github.com/crsh/depgraph

Provides an R function to plot the complete dependency graph of an R package and helps to cut down on dependencies.

https://github.com/crsh/depgraph

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
    2 of 3 committers (66.7%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (17.1%) to scientific vocabulary

Keywords from Contributors

apa apa-guidelines journal psychology reproducible-paper rmarkdown
Last synced: 10 months ago · JSON representation

Repository

Provides an R function to plot the complete dependency graph of an R package and helps to cut down on dependencies.

Basic Info
  • Host: GitHub
  • Owner: crsh
  • License: other
  • Language: R
  • Default Branch: main
  • Size: 649 KB
Statistics
  • Stars: 42
  • Watchers: 2
  • Forks: 2
  • Open Issues: 0
  • Releases: 0
Created over 5 years ago · Last pushed over 1 year ago
Metadata Files
Readme License

README.Rmd

---
output: github_document
---



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

set.seed(65787908)
```

# depgraph: Plot the complete dependency graph of an R package


[![CRAN/METACRAN](https://img.shields.io/cran/v/depgraph?label=CRAN&logo=r)](https://cran.r-project.org/web/packages/depgraph/index.html) [![Project Status: Active – The project has reached a stable, usable state and is being actively developed.](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active) ![GitHub last commit (devel)](https://img.shields.io/github/last-commit/crsh/depgraph/main?label=Last%20commit&logo=github&logoColor=%23FFF) [![GitHub bug issues](https://img.shields.io/github/issues/crsh/depgraph/bug?label=Bugs&logo=github&logoColor=%23FFF)](https://github.com/crsh/depgraph/issues?q=is%3Aopen+is%3Aissue+label%3Abug)


Provides a function to plot the complete dependency graph of an R package and helps to cut down on dependencies.

## Installation



You can install the development version from [GitHub](https://github.com/) with:

``` r
# install.packages("remotes")
remotes::install_github("crsh/depgraph")
```

## Example

Currently, `depgraph` ships only a single function that plots the dependency graph of an R package based on its `DESCRIPTION` file.
Consider the following example.

```{r fig.align = "center", fig.cap = "Dependency graph of a historic development version of the R package `multibridge`.", fig.height = 5, fig.width = 7, warning = FALSE}
library("depgraph")

plot_dependency_graph(
  pkg = multibridge_pkg
  , suggests = FALSE
  , option = "cividis"
)
```

Such plots can be used for at least two purposes:

1. Including dependency graphs in an R package `README` shows users how many packages their work depends on (indirectly).
This is useful as a very rough index of package reliability (less dependencies generally mean less potential for breaking upstream changes) and installation time.
2. Dependency graphs are useful to identify potential to cut down on dependencies.
Briefly, in these graphs you can look for "hot spots" in the network (big bright dots), which represent packages that have many upstream dependencies but are potentially easy to remove because they have few downstream dependencies (that is, only your package depends on them).

Some more details on how to use this graph to reduce package dependencies are given in the package vignette:

``` r
vignette("depgraph", package = "depgraph")
```

## Package dependencies

Yeah, I know...:see_no_evil:

```{r fig.align = "center", fig.cap = "Dependency graph of `depgraph`.", fig.height = 5, fig.width = 7, warning = FALSE}
plot_dependency_graph(
  pkg = "."
  , suggests = FALSE
  , option = "cividis"
)
```

Owner

  • Name: Frederik Aust
  • Login: crsh
  • Kind: user
  • Location: Cologne, Germany
  • Company: Psychological Methods, University of Amsterdam

GitHub Events

Total
  • Watch event: 3
  • Issue comment event: 1
  • Pull request event: 1
Last Year
  • Watch event: 3
  • Issue comment event: 1
  • Pull request event: 1

Committers

Last synced: about 1 year ago

All Time
  • Total Commits: 6
  • Total Committers: 3
  • Avg Commits per committer: 2.0
  • Development Distribution Score (DDS): 0.333
Past Year
  • Commits: 1
  • Committers: 1
  • Avg Commits per committer: 1.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
Frederik Aust f****t@u****e 4
Marius Barth m****h@u****e 1
Frederik Aust f****t@F****l 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: about 1 year ago

All Time
  • Total issues: 0
  • Total pull requests: 2
  • Average time to close issues: N/A
  • Average time to close pull requests: 3 months
  • Total issue authors: 0
  • Total pull request authors: 2
  • Average comments per issue: 0
  • Average comments per pull request: 1.5
  • Merged pull requests: 1
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 1
  • Average time to close issues: N/A
  • Average time to close pull requests: 6 months
  • Issue authors: 0
  • Pull request authors: 1
  • Average comments per issue: 0
  • Average comments per pull request: 2.0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
  • mariusbarth (1)
  • dungates (1)
Top Labels
Issue Labels
Pull Request Labels

Dependencies

DESCRIPTION cran
  • devtools * imports
  • ggnetwork * imports
  • ggplot2 * imports
  • grDevices * imports
  • igraph * imports
  • miniCRAN * imports
  • knitr * suggests
  • rmarkdown * suggests
data-raw/DESCRIPTION cran
  • R >= 3.5.0 depends
  • Brobdingnag * imports
  • DescTools * imports
  • Rcpp >= 0.12.17 imports
  • Rdpack * imports
  • coda * imports
  • magrittr * imports
  • mvtnorm * imports
  • progress * imports
  • purrr * imports
  • stringr * imports
  • knitr * suggests
  • rmarkdown * suggests
  • testthat * suggests