R/get_service_info.R

Defines functions get_service_info

Documented in get_service_info

#' Get Service Info
#'
#' @description General information about the GTEx service.
#'
#' [GTEx Portal API
#' documentation](https://gtexportal.org/api/v2/redoc#tag/GTEx-Portal-API-Info/operation/get_service_info_api_v2__get).
#'
#' @return A tibble.
#' @export
#' @family GTEx Portal API Info
#'
#' @examples
#' \dontrun{
#' get_service_info()
#' }
get_service_info <- function() {
  gtex_query(endpoint = NULL, return_raw = TRUE) |>
    purrr::map_at("organization", tibble::as_tibble) |>
    tibble::as_tibble() |>
    tidyr::unnest(cols = "organization", names_sep = "_")
}

Try the gtexr package in your browser

Any scripts or data that you put into this service are public.

gtexr documentation built on Sept. 19, 2024, 5:06 p.m.