forked from GuangchuangYu/badger
-
Notifications
You must be signed in to change notification settings - Fork 0
/
README.Rmd
157 lines (122 loc) · 5.04 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
---
output:
md_document:
variant: gfm
html_preview: false
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r echo=FALSE, results="hide", message=FALSE}
library("badger")
```
# badger: Badge for R Package
```{r, echo = FALSE, results='asis'}
cat(
badge_cran_release("badger", "green"),
badge_cran_download("badger", "grand-total", "green"),
badge_cran_download("badger", "last-month", "green"),
badge_cran_download("badger", "last-week", "green"),
badge_github_actions()
)
```
Query information and generate badge for using in README and GitHub Pages.
## :writing_hand: Author
Guangchuang YU <https://guangchuangyu.github.io>
School of Basic Medical Sciences, Southern Medical University
[![saythanks](https://img.shields.io/badge/say-thanks-ff69b4.svg)](https://saythanks.io/to/GuangchuangYu)
`r badger::badge_custom("follow me on", "WeChat", "green", "https://guangchuangyu.github.io/blog_images/biobabble.jpg")`
## :arrow_double_down: Installation
Get the released version from CRAN:
```r
install.packages("badger")
```
Or the development version from github:
```r
## install.packages("devtools")
devtools::install_github("GuangchuangYu/badger")
```
----
## :book: Examples
### Package Version
+ release version (bioconductor)
- syntax: `` ``r ''`r badge_bioc_release("ggtree", "green")` ``
- badge: `r badge_bioc_release("ggtree", "green")`
+ release version (CRAN)
- syntax: `` ``r ''`r badge_cran("badger", "orange")` ``
- badge: `r badge_cran_release("badger", "orange")`
+ devel version
- syntax: `` ``r ''`r badge_devel("guangchuangyu/ggtree", "blue")` ``
- badge: `r badge_devel("guangchuangyu/ggtree", "blue")`
### Download stats for bioconductor
+ Total of total :)
- syntax: `` ``r ''`r badge_bioc_download("clusterProfiler", "total", "blue",
"total")` ``
- badge: `r badge_bioc_download("clusterProfiler", "total", "blue",
"total")`
+ Total of distinct IPs
- syntax: `` ``r ''`r badge_bioc_download("clusterProfiler", "total", "yellow")` ``
- badge: `r badge_bioc_download("clusterProfiler", "total", "yellow")`
+ Monthly download of distinct IPs
- syntax: `` ``r ''`r badge_bioc_download("clusterProfiler", "month", "green")` ``
- badge: `r badge_bioc_download("clusterProfiler", "month", "green")`
### Download stats for CRAN
+ Total downloads
- syntax: `` ``r ''`r badge_cran_download("badger", "grand-total", "blue")` ``
- badge: `r badge_cran_download("badger", "grand-total", "blue")`
+ Monthly Downloads
- syntax: `` ``r ''`r badge_cran_download("badger", "last-month", "green")` ``
- badge: `r badge_cran_download("badger", "last-month", "green")`
+ Weekly Downloads
- syntax: `` ``r ''`r badge_cran_download("badger", "last-week", "yellow")` ``
- badge: `r badge_cran_download("badger", "last-week", "yellow")`
### Impact
+ Altmetric score
- syntax: `` ``r ''`r badge_altmetric("10533079", "green")` ``
- badge: `r badge_altmetric("10533079", "green")`
### Academic
+ DOI
- syntax: `` ``r ''`r badge_doi("10.1111/2041-210X.12628", "yellow")` ``
- badge: `r badge_doi("10.1111/2041-210X.12628", "yellow")`
### Customize badge
+ syntax: `` ``r ''`r badge_custom("1st most cited paper", "in OMICS", "blue",
"http://online.liebertpub.com/action/showMostCitedArticles?journalCode=omi")` ``
+ badge: `r badge_custom("1st most cited paper", "in OMICS", "blue",
"http://online.liebertpub.com/action/showMostCitedArticles?journalCode=omi")`
### Development
+ Lifecycle
- syntax: `` ``r ''`r badge_lifecycle("stable")` ``
- badge: `r badge_lifecycle("stable")`
+ Project status
- syntax: `` ``r ''`r badge_repostatus("Active")` ``
- badge: `r badge_repostatus("Active")`
+ License
- syntax: `` ``r ''`r badge_license("Artistic-2.0")` ``
- badge: `r badge_license("Artistic-2.0")`
+ travis build-status
- syntax: `` ``r ''`r badge_travis("rstudio/rmarkdown")` ``
- badge: `r badge_travis("rstudio/rmarkdown")`
+ coveralls code coverage
- syntax: `` ``r ''`r badge_coveralls("google/benchmark")` ``
- badge: `r badge_coveralls("google/benchmark")`
+ codecov code coverage
- syntax: `` ``r ''`r badge_codecov("rcannood/princurve")` ``
- badge: `r badge_codecov("rcannood/princurve")`
+ code size
- syntax: `` ``r ''`r badge_code_size("GuangchuangYu/badger")` ``
- badge: `r badge_code_size("GuangchuangYu/badger")`
+ last commit date
- syntax: `` ``r ''`r badge_last_commit("GuangchuangYu/badger")` ``
- badge: `r badge_last_commit("GuangchuangYu/badger")`
+ direct and recursive dependencies (for CRAN pkgs)
- syntax: `` ``r ''`r badge_dependencies("badger")` ``
- badge: `r badge_dependencies("badger")`
+ CRAN checks results
- syntax: `` ``r ''`r badge_cran_checks("badger")` ``
- badge: `r badge_cran_checks("badger")`
+ GitHub actions
- syntax: `` ``r ''`r badge_github_actions("rossellhayes/ipa")` ``
- badge: `r badge_github_actions("rossellhayes/ipa")`
+ CodeFactor code quality
- syntax: `` ``r ''`r badge_codefactor("rossellhayes/ipa")` ``
- badge: `r badge_codefactor("rossellhayes/ipa")`
## :hammer: Related Tools
+ [hexSticker](https://github.com/GuangchuangYu/hexSticker): create hexagon sticker in R