R/Pharma workshop: Good Software Engineering Practice for R Packages
October 28, 2024
pkgdown
pkgdown
pkgdown
makes it quick and easy to build a website for your packagepkgdown
, run usethis::use_pkgdown()
to get started_pkgdown.yml
filereference
section with names of .Rd
files_pkgdown.yml
File---
url: https://openpharma.github.io/mmrm/latest-tag
template:
bootstrap: 5
params:
ganalytics: UA-125641273-1
navbar:
right:
- icon: fa-github
href: https://github.com/openpharma/mmrm
reference:
- title: Package
contents:
- mmrm-package
- title: Functions
contents:
- mmrm
- fit_mmrm
- mmrm_control
- fit_single_optimizer
- refit_multiple_optimizers
- df_1d
- df_md
- component
gh-pages
, stores the rendered websitemain
branch is updatedusethis::use_pkgdown_github_pages()
pkgdown::deploy_to_branch()
usethis::use_mit_license()
for permissive MITusethis::use_gpl_license()
for copyleft GPLGPL (>= 3)
LICENSE
file optionally can contain further restrictions of the licenseVersion
field defines the package version.
or -
x.y-z
, equivalent to x.y.z
x
is major: Increment this for breaking changesy
is minor: Increment this for new featuresz
is patch: Increment this for bug fixes onlyx.y.z.9000
and count up during developmentusethis::use_version()
can help with this.rda
data files are allowedContact
field could be used<doi:...>
❗ A CRAN submission can be punishing, painful, and nerve-racking:
The first release of the rpact package took 5 weeks and 6 submission attempts; painful experiences:
Example message informing about the rejection of the last rpact submission:
Dear maintainer,
package rpact_3.3.2.tar.gz does not pass the incoming checks automatically, please see the following pre-tests:
Windows: 00check.log Status: OK, Debian: 00check.log Status: OKPlease fix all problems and resubmit a fixed version via the webform.
Best regards,
CRAN teams’ auto-check servicer-devel-windows-x86_64 Check: Result: NA, Maintainer: ‘Friedrich Pahlke’
r-devel-windows-x86_64 Check: Overall checktime, Result: NOTE, Overall checktime 12 min > 10 min
r-devel-linux-x86_64-debian-gcc Check: Result: Note_to_CRAN_maintainers Maintainer: ‘Friedrich Pahlke’
R CMD check
runs on different operating systems before submitting to CRANrhub::rhub_setup()
for setting up the GitHub actionrhub::rhub_check()
to check your packagevx.y.z
remotes::install_github("org/package", ref = "vx.y.z")
tar.gz
package files are rarely used directlyCreators (initial authors): Daniel Sabanes Bove , Friedrich Pahlke
In the current version, changes were done by (later authors): Liming Li , Philippe Boileau
This work is licensed under the Creative Commons Attribution-ShareAlike 4.0 International License.
The source files are hosted at github.com/openpharma/workshop-r-swe-rinpharma-2024, which is forked from the original version at github.com/RCONIS/user2024-tutorial-gswep.
Important: To use this work you must provide the name of the creators (initial authors), a link to the material, a link to the license, and indicate if changes were made