Package 'AnVILPublish'

Title: Publish Packages and Other Resources to AnVIL Workspaces
Description: Use this package to create or update AnVIL workspaces from resources such as R / Bioconductor packages. The metadata about the package (e.g., select information from the package DESCRIPTION file and from vignette YAML headings) are used to populate the 'DASHBOARD'. Vignettes are translated to python notebooks ready for evaluation in AnVIL.
Authors: Marcel Ramos [aut, cre] , Martin Morgan [aut] , Kayla Interdonato [aut], Vincent Carey [ctb]
Maintainer: Marcel Ramos <[email protected]>
License: Artistic-2.0
Version: 1.17.0
Built: 2024-11-13 06:15:17 UTC
Source: https://github.com/bioc/AnVILPublish

Help Index


Add Bioconductor_User group to workspace access

Description

add_access() adds the Bioconductor_User group to a workspace with READER permissions. Users gain access to the workspace (and others) by being added to the Bioconductor_User group.

Usage

add_access(namespace, name)

Arguments

namespace

character(1) namespace (billing account) under which the workspace belongs.

name

character(1) name of the workspace to add access credentials.

Value

add_access() returns TRUE, invisibly.


Render vignettes as .ipynb notebooks

Description

as_notebook() renders Rmarkdown (.Rmd) or Quarto (.Qmd) vignettes as Juptyer (.ipynb) notebooks. The vignettes and notebooks are updated in an AnVIL workspace.

Usage

as_notebook(
  rmd_paths,
  namespace,
  name,
  update = FALSE,
  type = c("ipynb", "rmd", "both"),
  quarto = c("render", "convert")
)

Arguments

rmd_paths

character() paths to Rmd or Qmd files.

namespace

character(1) AnVIL namespace (billing project) to be used.

name

character(1) AnVIL workspace name.

update

logical(1) Update (over-write any similarly named notebooks) an existing workspace? The default (FALSE) creates notebooks locally, e.g., for previewing via ⁠jupyter notebook *ipynb⁠.

type

character(1) The type of notebook to be copied to the workspace. Must be on of ipynb, rmd, or both. ipynb copies only the Jupyter notebook. rmd copies Rmarkdown and Quarto vignettes. both copies both notebooks and vignettes.

quarto

character(1) If the program Quarto is installed, this parameter indicates whether the .Rmd files will be rendered or converted. See vignette for more details.

Details

See the vignette "Publishing R / Bioconductor Packages To AnVIL Workspaces" for details on the conversion process; best results are obtained when Quarto software is available.

Value

as_notebook() returns the paths to the local (if update = FALSE) or the workspace notebooks.


Render R packages as AnVIL workspaces

Description

as_workspace() renders a package source tree (e.g., from a git checkout) as an AnVIL workspace.

Usage

as_workspace(
  path,
  namespace,
  name = NULL,
  create = FALSE,
  update = FALSE,
  use_readme = FALSE,
  type = c("ipynb", "rmd", "both"),
  quarto = c("render", "convert")
)

Arguments

path

character(1) path to the location of the package source code.

namespace

character(1) AnVIL namespace (billing project) to be used.

name

character(1) AnVIL workspace name.

create

logical(1) Create a new project?

update

logical(1) Update (over-write the existing DASHBOARD and any similarly named notebooks) an existing workspace? If neither create nor update is TRUE, the code to create a workspace is run but no output generated; this can be useful during debugging.

use_readme

logical(1) Defaults to FALSE; if TRUE the content of README.md in package top-level folder is used with the package DESCRIPTION version and provenance metadata for rendering in the workspace 'DASHBOARD'.

type

character(1) The type of notebook to be copied to the workspace. Must be on of ipynb, rmd, or both. ipynb copies only the Jupyter notebook. rmd copies Rmarkdown and Quarto vignettes. both copies both notebooks and vignettes.

quarto

character(1) If the program Quarto is installed, this parameter indicates whether the .Rmd files will be rendered or converted. See vignette for more details.

Details

Information from the DESCRIPTION file and Rmd YAML are used to populate the 'DASHBOARD' tab. See ?as_notebook() for details on how vignettes are processed to notebooks.

Value

as_workspace() returns the URL of the updated workspace, invisibly.