Skip to content

Commit

Permalink
add and update roxygen comments
Browse files Browse the repository at this point in the history
  • Loading branch information
ross-hull committed May 16, 2024
1 parent 55a8ab3 commit e2ca447
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
8 changes: 8 additions & 0 deletions R/get_dataset_additional_info.R
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
#' returns a list of dataset names alongwith additional information,
#' such as the amount of resources and the date it was last updated
#'
#' @param dataset_name
#'
#' @return
#' @export
#'
get_datasets_additional_info <- function(dataset_name){

Check warning on line 9 in R/get_dataset_additional_info.R

View workflow job for this annotation

GitHub Actions / lint

file=R/get_dataset_additional_info.R,line=9,col=55,[brace_linter] There should be a space before an opening curly brace.

Check warning on line 9 in R/get_dataset_additional_info.R

View workflow job for this annotation

GitHub Actions / lint

file=R/get_dataset_additional_info.R,line=9,col=55,[paren_body_linter] There should be a space between a right parenthesis and a body expression.
query <- paste0("id=", dataset_name)
content <- phs_GET("package_show", query)
Expand Down
4 changes: 4 additions & 0 deletions R/list_datasets.R
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,15 @@
#'
#' `list_datasets()` shows all of the datasets hosted on the phs open data platform.
#'
#' @param include_additional_info (optional) set to true to return the number
#' of resources per dataset and the date the dataset was last updated
#'
#' @return A character vector.
#' @export
#'
#' @examples
#' head(list_datasets())
#' head(list_datasets(include_additional_info = T))
#'
list_datasets <- function(include_additional_info = F) {
data_sets <- phs_GET("package_list", "")$result
Expand Down

0 comments on commit e2ca447

Please sign in to comment.