Skip to content

Commit f3c76c7

Browse files
committed
docs: updating badges
1 parent e20e46e commit f3c76c7

File tree

4 files changed

+33
-28
lines changed

4 files changed

+33
-28
lines changed

.github/workflows/R-CMD-check.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
pull_request:
77
branches: [main, master]
88

9-
name: R-CMD-check.yaml
9+
name: R-CMD-check
1010

1111
permissions: read-all
1212

.github/workflows/check-no-suggests.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ on:
1111
branches: [main, master]
1212
pull_request:
1313

14-
name: check-no-suggests.yaml
14+
name: check-no-suggests
1515

1616
permissions: read-all
1717

README.Rmd

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,9 @@ knitr::opts_chunk$set(
1616
# openFDA
1717

1818
<!-- badges: start -->
19-
[![R-CMD-check](https://github.com/simpar1471/openFDA/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/simpar1471/openFDA/actions/workflows/R-CMD-check.yaml)
20-
[![Project Status: WIP -- Initial development is in progress, but there has not yet been a stable, usable release suitable for the public.](https://www.repostatus.org/badges/latest/wip.svg)](https://www.repostatus.org/#wip)
19+
[![CRAN status](https://www.r-pkg.org/badges/version/openFDA)](https://CRAN.R-project.org/package=openFDA)
20+
[![R-CMD-check](https://github.com/simpar1471/openFDA/actions/workflows/R-CMD-check/badge.svg)](https://github.com/simpar1471/openFDA/actions/workflows/R-CMD-check.yaml)
21+
[![R-CMD-check-no-suggests](https://github.com/simpar1471/openFDA/actions/workflows/check-no-suggests/badge.svg)](https://github.com/simpar1471/openFDA/actions/workflows/check-no-suggests.yaml)
2122
[![Codecov test coverage](https://codecov.io/gh/simpar1471/openFDA/graph/badge.svg)](https://app.codecov.io/gh/simpar1471/openFDA)
2223
<!-- badges: end -->
2324

@@ -28,17 +29,18 @@ Note that the data on openFDA has not been validated for clinical or production
2829

2930
## Installation
3031

31-
You can install the development version of openFDA from GitHub using either
32-
[pak](https://pak.r-lib.org/) or [devtools](https://devtools.r-lib.org/):
33-
3432
```r
35-
# install.packages("pak")
36-
pak::pkg_install("simpar1471/openFDA")
33+
# The easiest way to get openFDA is to install it from CRAN:
34+
install.packages("openFDA")
3735
```
3836

37+
### Dev version
38+
Alternatively, you can install the development version of openFDA from GitHub using either
39+
[pak](https://pak.r-lib.org/):
40+
3941
```r
40-
# install.packages("devtools")
41-
devtools::install_github("simpar1471/openFDA")
42+
# install.packages("pak")
43+
pak::pkg_install("simpar1471/openFDA")
4244
```
4345

4446
## Using openFDA

README.md

Lines changed: 20 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55

66
<!-- badges: start -->
77

8-
[![R-CMD-check](https://github.com/simpar1471/openFDA/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/simpar1471/openFDA/actions/workflows/R-CMD-check.yaml)
9-
[![Project Status: WIP – Initial development is in progress, but there
10-
has not yet been a stable, usable release suitable for the
11-
public.](https://www.repostatus.org/badges/latest/wip.svg)](https://www.repostatus.org/#wip)
8+
[![CRAN
9+
status](https://www.r-pkg.org/badges/version/openFDA)](https://CRAN.R-project.org/package=openFDA)
10+
[![R-CMD-check](https://github.com/simpar1471/openFDA/actions/workflows/R-CMD-check/badge.svg)](https://github.com/simpar1471/openFDA/actions/workflows/R-CMD-check.yaml)
11+
[![R-CMD-check-no-suggests](https://github.com/simpar1471/openFDA/actions/workflows/check-no-suggests/badge.svg)](https://github.com/simpar1471/openFDA/actions/workflows/check-no-suggests.yaml)
1212
[![Codecov test
1313
coverage](https://codecov.io/gh/simpar1471/openFDA/graph/badge.svg)](https://app.codecov.io/gh/simpar1471/openFDA)
1414
<!-- badges: end -->
@@ -22,18 +22,19 @@ validated for clinical or production use.
2222

2323
## Installation
2424

25-
You can install the development version of openFDA from GitHub using
26-
either [pak](https://pak.r-lib.org/) or
27-
[devtools](https://devtools.r-lib.org/):
28-
2925
``` r
30-
# install.packages("pak")
31-
pak::pkg_install("simpar1471/openFDA")
26+
# The easiest way to get openFDA is to install it from CRAN:
27+
install.packages("openFDA")
3228
```
3329

30+
### Dev version
31+
32+
Alternatively, you can install the development version of openFDA from
33+
GitHub using either [pak](https://pak.r-lib.org/):
34+
3435
``` r
35-
# install.packages("devtools")
36-
devtools::install_github("simpar1471/openFDA")
36+
# install.packages("pak")
37+
pak::pkg_install("simpar1471/openFDA")
3738
```
3839

3940
## Using openFDA
@@ -61,7 +62,7 @@ search
6162
#> https://api.fda.gov/drug/drugsfda.json?api_key=[API_KEY]&search=openfda.generic_name:furosemide&limit=5
6263
#> Status: 200 OK
6364
#> Content-Type: application/json
64-
#> Body: In memory (17286 bytes)
65+
#> Body: In memory (26060 bytes)
6566
```
6667

6768
The underlying response is JSON data - you can use
@@ -73,7 +74,7 @@ json <- httr2::resp_body_json(search)
7374

7475
json$results[[1]]$openfda$brand_name
7576
#> [[1]]
76-
#> [1] "FUROSEMIDE"
77+
#> [1] "FUROSCIX"
7778
json$results[[1]]$openfda$pharm_class_epc
7879
#> [[1]]
7980
#> [1] "Loop Diuretic [EPC]"
@@ -87,9 +88,11 @@ purrr::map_chr(
8788
.x = json$results,
8889
.f = \(result) purrr::pluck(result, "openfda", "manufacturer_name", 1)
8990
)
90-
#> [1] "Amneal Pharmaceuticals LLC" "Gland Pharma Limited"
91-
#> [3] "Solco Healthcare LLC" "Lifestar Pharma LLC"
92-
#> [5] "Ipca Laboratories Limited"
91+
#> [1] "scPharmaceuticals Inc."
92+
#> [2] "Graviti Pharmaceuticals Private Limited"
93+
#> [3] "Hikma Pharmaceuticals USA Inc."
94+
#> [4] "Civica, Inc."
95+
#> [5] "Eugia US LLC"
9396
```
9497

9598
## Other R packages for openFDA

0 commit comments

Comments
 (0)