---
title: "biocthis developer notes"
author: 
  - name: Leonardo Collado-Torres
    affiliation:
    - &libd Lieber Institute for Brain Development, Johns Hopkins Medical Campus
    - &ccb Center for Computational Biology, Johns Hopkins University
    email: lcolladotor@gmail.com
output: 
  BiocStyle::html_document:
    self_contained: yes
    toc: true
    toc_float: true
    toc_depth: 3
    code_folding: show
date: "`r doc_date()`"
package: "`r pkg_ver('biocthis')`"
vignette: >
  %\VignetteIndexEntry{biocthis developer notes}
  %\VignetteEngine{knitr::rmarkdown}
  %\VignetteEncoding{UTF-8}  
---

```{r setup, include = FALSE}
knitr::opts_chunk$set(
    collapse = TRUE,
    comment = "#>",
    crop = NULL ## Related to https://stat.ethz.ch/pipermail/bioc-devel/2020-April/016656.html
)
```


```{r vignetteSetup, echo=FALSE, message=FALSE, warning = FALSE}
## Track time spent on making the vignette
startTime <- Sys.time()

## Bib setup
library("RefManageR")

## Write bibliography information
bib <- c(
    R = citation(),
    BiocStyle = citation("BiocStyle")[1],
    biocthis = citation("biocthis")[1],
    covr = citation("covr")[1],
    devtools = citation("devtools")[1],
    fs = citation("fs")[1],
    glue = citation("glue")[1],
    knitr = citation("knitr")[1],
    pkgdown = citation("pkgdown")[1],
    rlang = citation("rlang")[1],
    RefManageR = citation("RefManageR")[1],
    rmarkdown = citation("rmarkdown")[1],
    sessioninfo = citation("sessioninfo")[1],
    styler = citation("styler")[1],
    testthat = citation("testthat")[1],
    usethis = citation("usethis")[1]
)
```

Note that `r Biocpkg("biocthis")` is not a Bioconductor-core package and as such it is not a Bioconductor official package. It was made by and for Leonardo Collado-Torres so he could more easily maintain and create Bioconductor packages as listed at [lcolladotor.github.io/pkgs/](https://lcolladotor.github.io/pkgs/). Hopefully `r Biocpkg("biocthis")`  will be helpful for you too.


# Basics

For the basics, please check the [`Introduction to biocthis` vignette](https://lcolladotor.github.io/biocthis/articles/biocthis.html).

# `biocthis` developer notes

## Backstory

In 2019, I was able to take the ["Building Tidy Tools"](https://rstd.io/tidytools19) workshop taught by [Charlotte](https://twitter.com/CVWickham) and [Hadley](https://twitter.com/hadleywickham) Wickham during [`rstudio::conf(2019)`](https://blog.rstudio.com/2019/02/06/rstudio-conf-2019-workshops/) thanks to a diversity scholarship. During this workshop, I learned about `r CRANpkg("usethis")` `r Citep(bib[["usethis"]])`, `r CRANpkg("devtools")` `r Citep(bib[["devtools"]])`, `r CRANpkg("testthat")` `r Citep(bib[["testthat"]])`, among other R packages, and how to use [RStudio Desktop](https://www.rstudio.com/products/rstudio/download) to create R packages more efficiently. I got to revise this material and practice it more for the [CDSB Workshop 2019: How to Build and Create Tidy Tools](https://comunidadbioinfo.github.io/post/building-tidy-tools-cdsb-runconf-2019/#.XrbLMxNKiu4) where we re-used the materials (with their permission) and translated them to Spanish. Over the years I have made several [Bioconductor](http://bioconductor.org/) R packages that [I maintain](https://lcolladotor.github.io/pkgs/). Yet I learned a lot thanks to Charlotte and Hadley and have been relying more and more on `r CRANpkg("usethis")` and related packages. 

Earlier this year (2020) one of my Bioconductor packages (`r Biocpkg("regionReport")`) was presenting some errors on some operating systems but not on others. I first spent quite a bit of time [setting up the corresponding R installation](https://stat.ethz.ch/pipermail/bioc-devel/2020-March/016365.html) in my non-work Windows computer. I still struggled to reproduce the error, so I finally learned how to use the [Bioconductor docker images](https://www.bioconductor.org/help/docker/). That is, run the following code to then have an environment with all the system dependencies installed for Bioconductor packages. In this system you can then install your package dependencies and get very close to the Linux environment machine used for testing Bioconductor packages.

```{bash, eval = FALSE}
docker run \
    -e PASSWORD=bioc \
    -p 8787:8787 \
    bioconductor/bioconductor_docker:devel
```

Using this docker image, I was finally [able to reproduce the error](https://stat.ethz.ch/pipermail/bioc-devel/2020-April/016532.html) which involved others Bioconductor packages. However, there was a second hard-to-reproduce error. Using [GitHub Actions](https://github.com/features/actions), which I'll talk about more soon, I was then able to find the [root cause of this second issue](https://stat.ethz.ch/pipermail/bioc-devel/2020-April/016650.html) and resolve it.

`r Biocpkg("biocthis")` `r Citep(bib[['biocthis']])` was born from my interest to keep using `r CRANpkg("usethis")` and related tools, but in a Bioconductor-friendly way. That is, this is a package that will help me (and maybe others too). This package was born from these 5 issues:

* _Bioconductor-friendly R CMD check action feature suggestion_ [r-lib/actions#84](https://github.com/r-lib/actions/issues/84)
* _Bioc-friendly feature suggestions_ [r-lib/usethis#1108](https://github.com/r-lib/usethis/issues/1108)
* _Bioc-friendly style feature suggestion_ [r-lib/styler#636](https://github.com/r-lib/styler/issues/636)
* _Recommend `styler` over `formatR` suggestion_ [Bioconductor/BiocCheck#57](https://github.com/Bioconductor/BiocCheck/issues/57)
* _GitHub actions and styler suggestions_ [Bioconductor/bioconductor.org#54](https://github.com/Bioconductor/bioconductor.org/issues/54)


## Styling code

`r Biocpkg("BiocCheck")` is run on all new Bioconductor package submissions and by default it checks whether the new package adheres to the [Bioconductor coding style guide](http://bioconductor.org/developers/how-to/coding-style/). For a long time, it has suggested `r CRANpkg("formatR")` as a solution for automatically styling code in an R package. While `r CRANpkg("formatR")` mostly works and I've used it before, I recently discovered `r CRANpkg("styler")` which can be used for styling code to fit the [tidyverse coding style guide](https://style.tidyverse.org/). On my own packages, I have found `r CRANpkg("styler")` to be superior to `r CRANpkg("formatR")` because it: 

* breaks less code,
* can format `r CRANpkg("roxygen2")` example code,
* and can re-format R Markdown files like vignettes.
* Plus it seems to me to be under active maintenance, which is always a good thing.

Several of the issues I made are related to using `r CRANpkg("styler")` to automatically re-format your code to match more closely the Bioconductor coding style guide. That is how `bioc_style()` was born and it was the suggested approach as discussed at _Bioc-friendly style feature suggestion_ [r-lib/styler#636](https://github.com/r-lib/styler/issues/636). The maintainer of `r CRANpkg("styler")`, [Lorenz Walthert](https://twitter.com/lorenzwalthert), has a great reply on that issue linking for a more detailed discussion on how to expand `r CRANpkg("styler")` if the job requires doing so.

Currently, `bioc_style()` does not fully replicate the Bioconductor coding style, but it gets close enough. As [Martin Morgan](https://twitter.com/mt_morgan) said at _Recommend `styler` over `formatR` suggestion_ [Bioconductor/BiocCheck#57](https://github.com/Bioconductor/BiocCheck/issues/57), a solution that gets 90% of the way is good enough. `bioc_style()` is a very short function, mostly because the Bioconductor and Tidyverse coding style guides are overall very similar. This function won't solve all the formatting issues detected by `r Biocpkg("BiocCheck")`, but if you really want to, you can disable the formatting checks with:

```{r bioccheck_example, eval = FALSE}
## Use the following for the latest options
BiocCheck::usage()
## Disable formatting checks
BiocCheck::BiocCheck(`--no-check-formatting` = TRUE)
```

## GitHub Actions

### Motivation

I have been using [Travis CI](https://docs.travis-ci.com/user/languages/r/) for several years now to help me run `R CMD check` every time I make a commit and push it to `GitHub`. `Travis CI` has mostly worked well for me, though I frequently had to maneuver around the 50 minute limit. I also recently [ran into a problem](https://github.com/r-lib/pkgdown/issues/1206) where Hadley Wickham replied "We now recommend using the github actions workflow instead; which avoids all this configuration pain". I also [ran into a problem](https://github.com/r-lib/pkgdown/issues/1230) that didn't always happen in Travis CI but that was potentially related to the computational resources provided (memory). I heard the term `GitHub Actions` at `rstudio::conf(2020)` but I ended up missing [Jim Hester](https://twitter.com/jimhester_)'s talk which you can [watch online](https://www.jimhester.com/talk/2020-rsc-github-actions/): I highly recommend it and wish I had started my adventure into GitHub Actions with it. Briefly, [GitHub Actions](https://github.com/features/actions) allows you to run checks on Windows, macOS or Linux for up to 6 hours on machines with 7 GB of RAM. That's two more operating systems than what I was using with `Travis CI`, a significant amount longer of time, and a decent chunk of memory.

The significance of these 3 operating systems is important to me because [Bioconductor runs nightly checks](https://github.com/Bioconductor/BBS) on those 3 platforms. It's a great way to know if your Bioconductor R package will work for most users. However, you only get one report per day. If you are not the most organized person like me, and have to fix your code before a release, then you don't have as many days to check your R package(s) and need more frequent feedback. So I've been looking for a way to run checks on all three platforms on demand. Bioconductor has a [Single Package Builder](https://github.com/Bioconductor/packagebuilder) which does this, but it is restricted to new package submissions.

I know that there's [AppVeyor](https://www.appveyor.com/) for running checks on Windows, but I never used it. Travis CI does support macOS and Linux. In the past, I have used `r Githubpkg("r-hub/rhub")` and I was able to run tests on a package using a combination of `Travis CI` and `rhub` as detailed at [r-hub/rhub/issues#52](https://github.com/r-hub/rhub/issues/52). `rhub` maintainers have also taken steps to support Bioconductor's release cycle as described at [r-hub/rhub/issues#38](https://github.com/r-hub/rhub/issues/38). Regardless of the platform, it would ultimately be nice to have a single configuration file that you (the package developer) don't need to update for every Bioconductor release cycle.

### Developing a Bioconductor-friendly GHA workflow

I saw on Twitter the [announcement about GitHub Actions](https://www.tidyverse.org/blog/2020/04/usethis-1-6-0/) in `r CRANpkg("usethis")` and that is when I started to look more into `r CRANpkg("usethis")` and `r Githubpkg("r-lib/actions")` by Jim Hester, particularly [r-lib/actions/examples](https://github.com/r-lib/actions/tree/master/examples). As [my usual](https://yihui.org/en/2018/03/second-pull-request/), I tried to just get it to work and then had to look more closely at the documentation and the code. Naively, I thought that I could make [r-lib/actions/examples/check-standard.yaml](https://github.com/r-lib/actions/blob/master/examples/check-standard.yaml) Bioconductor-friendly, which Jim Hester immediately recognized as a complicated task. As you can see at _Bioconductor-friendly R CMD check action feature suggestion_ [r-lib/actions#84](https://github.com/r-lib/actions/issues/84) this took a while. When working on this, I also looked at several other resources and real world examples:

* The GitHub Actions reference manual: https://help.github.com/en/actions
* An `rOpenSci` book on GitHub Actions: https://ropenscilabs.github.io/actions_sandbox/
* [Sean Davis](https://twitter.com/seandavis12)' GHA workflow [seandavi/BiocActions/.github/workflows/main.yml](https://github.com/seandavi/BiocActions/blob/master/.github/workflows/main.yml) and [Charlotte Soneson](https://twitter.com/CSoneson)'s GHA workflow  [csoneson/dreval/.github/workflows/R-CMD-check.yaml](https://github.com/csoneson/dreval/blob/master/.github/workflows/R-CMD-check.yaml) which I found searching some keywords on the [Bioconductor Slack workspace](https://bioc-community.herokuapp.com/).
* Sean Davis' [blog post on GHA workflows](https://seandavi.github.io/post/learning-github-actions/).

Most of the development of the Bioconductor-friendly GitHub Actions workflow provided by `r Biocpkg("biocthis")` was done with [leekgroup/derfinderPlot/.github/workflows/check-bioc.yml](https://github.com/leekgroup/derfinderPlot/blob/master/.github/workflows/check-bioc.yml) and  [LieberInstitute/recount3/.github/workflows/check-bioc.yml](https://github.com/LieberInstitute/recount3/blob/master/.github/workflows/check-bioc.yml) as detailed at: _Bioconductor-friendly R CMD check action feature suggestion_ [r-lib/actions#84](https://github.com/r-lib/actions/issues/84). It was then further improved by a [pull request](https://github.com/lcolladotor/biocthis/pull/11) with tests carried out at [lcolladotor/testmatrix](https://github.com/lcolladotor/testmatrix/).

This work eventually lead to `use_bioc_github_action()` as it is today. The features of this GHA workflow are described in the `Introduction to biocthis` vignette. Going back to the story about developing this GHA workflow, while working on this GHA workflow, I ran into several issues and I wouldn't be surprised if we run into more of them later on.

* R has more tags than just `release` and `devel`, so just before R 4.0.0 was released it was called `alpha`, while `release` pointed to 3.6.3 and `devel` to 4.1.0. At [r-lib/actions/pull/68](https://github.com/r-lib/actions/pull/68) the decision was made that this was a transient issue. In the meantime I wanted to get the GHA to work, this lead me to many issues about installing package dependencies on R 4.1.0 to test Bioconductor 3.11, which is **NOT** the thing you should do! Bioconductor 3.11 is meant to run on R 4.0.x, not 4.1.x. [Hervé Pagès](https://github.com/hpages) helped me with some of these tricks, particularly with Windows. Also on Windows, I learned more about `r-lib/actions` from the update to [support Rtools 4.0 on Windows](https://github.com/r-lib/actions/pull/85) by [Jeroen Ooms](https://twitter.com/opencpu), which [Constantin AE](https://community.rstudio.com/u/const-ae) and I were discussing on the [RStudio Community website](https://community.rstudio.com/t/compiler-support-fo-c-14-features-on-windows/57284/4). On macOS I ran into compiling `r CRANpkg("XML")` from source and its system dependencies. I also ran into [xml2/issues/296](https://github.com/r-lib/xml2/issues/296) which is now officially resolved thanks to [xml2/issues/302](https://github.com/r-lib/xml2/issues/302), though looking at [r-lib/usethis/.github/workflows/R-CMD-check.yaml](https://github.com/r-lib/usethis/blob/master/.github/workflows/R-CMD-check.yaml) and [r-lib/usethis/commits/.github/workflows/R-CMD-check.yaml](https://github.com/r-lib/usethis/commits/master/.github/workflows/R-CMD-check.yaml) was very helpful.
* I had some issues installing `r Biocpkg("BiocCheck")` and running `R CMD BiocCheck` on both Windows and the Bioconductor docker image (different issues) that I can avoid using code like this: `Rscript -e "BiocCheck::BiocCheck()"`.
* Apparently, we found a bug in the internal R code. It's my second issue ever that traces back to the R internals! This is something we discussed quite a bit at the Bioc-devel mailing list with Martin Morgan, Charlotte Soneson and others. Check [this message](https://stat.ethz.ch/pipermail/bioc-devel/2020-April/016703.html) and the [April thread history](https://stat.ethz.ch/pipermail/bioc-devel/2020-April/thread.html). I thought that it was linked to [r-lib/remotes/issues/296](https://github.com/r-lib/remotes/issues/296) at some point.
* I learned about caching on GitHub actions at [r-lib/actions/issues/86](https://github.com/r-lib/actions/issues/86) in general, I've been trying to update the GHA workflow here to reflect changes at `r Githubpkg("r-lib/actions")`.
* I ran into some issues configuring `git` to then run `r CRANpkg("pkgdown")`, which involved the `GITHUB_TOKEN` environment variable on the Bioconductor docker step and using `git config --local` a couple of times. You will also need to run `pkgdown::deploy_to_branch()` once locally to set up the `gh-pages` branch properly for `r CRANpkg("pkgdown")` to work from GitHub Actions.
* I ran into a small issue [r-lib/covr/issues/427](https://github.com/r-lib/covr/issues/427) with `r CRANpkg("covr")` in case your package doesn't have tests. This and the caching discussion, along with [r-lib/actions/examples/pr-commands.yaml](https://github.com/r-lib/actions/blob/master/examples/pr-commands.yaml) motivated me to use environment variables and conditionals to have a single workflow with some options at the top that you can set to run: `r CRANpkg("covr")`, extract info from `r CRANpkg("testthat")`, run `r CRANpkg("pkgdown")`, or ignore the cache by including the keyword `/nocache` on your commit message.
* I had to learn how to compile `git` from source by modifying [these instructions](https://www.digitalocean.com/community/tutorials/how-to-install-git-on-ubuntu-18-04) in order to have a `git` version equal or newer to 2.18 on Ubuntu 18.04 such that I can then use `actions/checkout@v2` and avoid issues with running `r CRANpkg("pkgdown")`. I later learned how to use a [ppa](https://launchpad.net/~git-core/+archive/ubuntu/candidate) for Ubuntu for installing the latest `git` version. If you use `actions/checkout@v1` you can end up at [r-lib/actions/issues/50](https://github.com/r-lib/actions/issues/50). If you use the default `git` 2.17.1 on Ubuntu 18.04 then you run into [actions/checkout/issues/238](https://github.com/actions/checkout/issues/238) and other related issues. I could have avoided this by running `r CRANpkg("pkgdown")` on macOS instead of the Bioconductor docker image that is based on [`rockerdev/rstudio:R.4.0.0_ubuntu18.04`](https://github.com/rocker-org/rocker-versioned2/blob/master/dockerfiles/Dockerfile_rstudio_4.0.0-ubuntu18.04). Nowadays, the bioconductor docker devel images are based on Ubuntu 20.04, known as `focal`. The [RStudio Package Manager](https://rstudio.com/products/package-manager/) (RSPM) greatly improves the speed at which R packages are installed in Linux and thus on the Bioconductor docker images. Since August 2022, ubuntu-latest changed to Ubuntu 22.04, also known as `jammy`.
* [Nitesh Turaga](https://twitter.com/niteshturaga) and [Carl Boettiger](https://twitter.com/cboettig) [rocker-org/rocker-versioned/issues/208](https://github.com/rocker-org/rocker-versioned/issues/208) updated the rocker docker image for RStudio to R 4.0 and the corresponding Bioconductor docker image. To do so, they resolved several issues themselves. From my side, I only had to wait =)
* I also had to learn how to mount directories with docker to enable caching the R package files when using the Bioconductor docker images, and other GitHub Actions syntax for which I relied quite heavily on [their manual](https://help.github.com/en/actions) and Google searches; most of them lead me to the [GitHub Actions community website](https://github.community/t5/GitHub-Actions/bd-p/actions).
* In late September 2020, [Marcel Ramos](https://twitter.com/M2RUseR) sent a [pull request](https://github.com/lcolladotor/biocthis/pull/11) that greatly changed the GHA actions workflow to (1) use a template and (2) avoid the code redundancy across macOS, Windows and Linux (running a Bioconductor docker), which makes the resulting GHA workflow easier to understand and customize.

### Potential future additions

* It might be useful to use exactly the same `.Renviron` as the one used in the Bioconductor machines by downloading files like [3.11/Renviron.bioc](https://github.com/Bioconductor/BBS/blob/master/3.11/Renviron.bioc) and locating them correctly.
* On a similar route, it might be useful to utilize `r Githubpkg("HenrikBengtsson/rcli")`, potentially avoiding the need for dealing directly with the `.Renviron` files.

### Wrapping up

The resulting Bioconductor-friendly GitHub Actions workflow that you can add to your package with `biocthis::use_bioc_github_action()` has many comments which you might find helpful for understanding why some steps are done the way they are. I have tried to simplify the workflow when possible, but it depends on the latest version of many tools and thus will expose you to issues you might have not dealt with, particularly compilation issues of R packages with R-devel (six months of the year with the current Bioconductor release cycle). If you need help, start by going through the steps listed at [r-lib/actions#where-to-find-help](https://github.com/r-lib/actions#where-to-find-help). `r Biocpkg("biocthis")` exclusive issues are always welcome, though please include the information that will enable others to help you faster. Thank you!


## `usethis`-like functions

`r Biocpkg("biocthis")` also provides other `r CRANpkg("usethis")`-like functions. To make these functions, I looked at the code inside `r CRANpkg("usethis")` and learned how to make templates, how the data is passed to the templates and some other steps. Some of the functions are really identical to the ones from `r CRANpkg("usethis")` but point to a custom template provided by `r Biocpkg("biocthis")`. These functions have simplified for me the task of having uniform README.Rmd/md and vignette files for instance, as well as having GitHub issue & support templates that include some Bioconductor-specific information and some of my own personal preferences for asking for help. I also included template R scripts through `use_bioc_pkg_templates()` that is an idea I first learned at `rstudio::conf(2020)` on the `r CRANpkg("golem")` package. Those scripts are useful to keep track of code that you had to run to make the R package or to update it later. These scripts can greatly jump-start your R/Bioconductor package creation process. So maybe you'll see more packages by me and others soon =) In particular, I really hope that we can get more CDSB members to submit R/Bioconductor packages to the world as explained in [this story](https://www.r-consortium.org/blog/2020/03/18/cdsb-diversity-and-outreach-hotspot-in-mexico), which is something I care about quite a bit.

# Acknowledgments

I just want to thank everyone for helping me understand different pieces of code, for producing the tools I used, for interacting with me across many GitHub issues, as well as answering questions on multiple mailing lists. The names below are in order they appear in this vignette:

* [Charlotte Wickham](https://twitter.com/CVWickham)
* [Hadley Wickham](https://twitter.com/hadleywickham)
* [Lorenz Walthert](https://twitter.com/lorenzwalthert)
* [Martin Morgan](https://twitter.com/mt_morgan)
* [Jim Hester](https://twitter.com/jimhester_)
* [Sean Davis](https://twitter.com/seandavis12)
* [Charlotte Soneson](https://twitter.com/CSoneson)
* [Hervé Pagès](https://github.com/hpages)
* [Jeroen Ooms](https://twitter.com/opencpu)
* [Constantin AE](https://community.rstudio.com/u/const-ae)
* [Max Held](https://github.com/maxheld83) for [r-lib/actions/pull/87](https://github.com/r-lib/actions/pull/87)
* [Hiroaki Yutani](https://github.com/yutannihilation) for [r-lib/actions/issues/86](https://github.com/r-lib/actions/issues/86)
* [Nitesh Turaga](https://twitter.com/niteshturaga)
* [Carl Boettiger](https://twitter.com/cboettig)
* [Jenny Bryan](https://twitter.com/JennyBryan) for her feedback at [r-lib/usethis/issues#1108](https://github.com/r-lib/usethis/issues/1108#issuecomment-626253251)
* [Marcel Ramos](https://twitter.com/M2RUseR) for this [awesome pull request](https://github.com/lcolladotor/biocthis/pull/11)

as well as several organizations and members:

* [Bioconductor](https://twitter.com/Bioconductor), particularly [Lori Shepard](https://twitter.com/lshep712) and other members I mentioned already
* [RStudio](https://twitter.com/rstudio)
* [CDSB](https://twitter.com/CDSBMexico)
* [Travis CI](https://twitter.com/travisci)
* [rhub](https://twitter.com/rhub_), particularly [Maëlle Salmon](https://twitter.com/ma_salmon) and [Gábor Csárdi](https://twitter.com/GaborCsardi)
* [GitHub](https://twitter.com/github)
* [CRAN](https://cran.r-project.org/), particularly [Simon Urbanek](https://github.com/s-u) for his help with understanding the changes in R 4.0.0 and the macOS toolchain.
* [R Consortium](https://twitter.com/RConsortium), particularly [Joseph Rickert](https://twitter.com/RStudioJoe)


Thank you very much! 🙌🏽😊

# Reproducibility

The `r Biocpkg("biocthis")` package `r Citep(bib[['biocthis']])` was made possible thanks to:

* R `r Citep(bib[["R"]])`
* `r Biocpkg("BiocStyle")` `r Citep(bib[["BiocStyle"]])`
* `r CRANpkg("covr")` `r Citep(bib[["covr"]])`
* `r CRANpkg("devtools")` `r Citep(bib[["devtools"]])`
* `r CRANpkg("fs")` `r Citep(bib[["fs"]])`
* `r CRANpkg("glue")` `r Citep(bib[["glue"]])`
* `r CRANpkg("knitr")` `r Citep(bib[["knitr"]])`
* `r CRANpkg("pkgdown")` `r Citep(bib[["pkgdown"]])`
* `r CRANpkg("rlang")` `r Citep(bib[["rlang"]])`
* `r CRANpkg("RefManageR")` `r Citep(bib[["RefManageR"]])`
* `r CRANpkg("rmarkdown")` `r Citep(bib[["rmarkdown"]])`
* `r CRANpkg("sessioninfo")` `r Citep(bib[["sessioninfo"]])`
* `r CRANpkg("styler")` `r Citep(bib[["styler"]])`
* `r CRANpkg("testthat")` `r Citep(bib[["testthat"]])`
* `r CRANpkg("usethis")` `r Citep(bib[["usethis"]])`

This package was developed using `r BiocStyle::Githubpkg('lcolladotor/biocthis')`.


Code for creating the vignette

```{r createVignette, eval=FALSE}
## Create the vignette
library("rmarkdown")
system.time(render("biocthis_dev_notes.Rmd", "BiocStyle::html_document"))

## Extract the R code
library("knitr")
knit("biocthis_dev_notes.Rmd", tangle = TRUE)
```

Date the vignette was generated.

```{r reproduce1, echo=FALSE}
## Date the vignette was generated
Sys.time()
```

Wallclock time spent generating the vignette.

```{r reproduce2, echo=FALSE}
## Processing time in seconds
totalTime <- diff(c(startTime, Sys.time()))
round(totalTime, digits = 3)
```

`R` session information.

```{r reproduce3, echo=FALSE}
## Session info
library("sessioninfo")
options(width = 120)
session_info()
```



# Bibliography

This vignette was generated using `r Biocpkg('BiocStyle')` `r Citep(bib[['BiocStyle']])`
with `r CRANpkg('knitr')` `r Citep(bib[['knitr']])` and `r CRANpkg('rmarkdown')` `r Citep(bib[['rmarkdown']])` running behind the scenes.

Citations made with `r CRANpkg('RefManageR')` `r Citep(bib[['RefManageR']])`.

```{r vignetteBiblio, results = 'asis', echo = FALSE, warning = FALSE, message = FALSE}
## Print bibliography
PrintBibliography(bib, .opts = list(hyperlink = "to.doc", style = "html"))
```
