galaxy_history_size: Galaxy history size Get the disk usage / size of a Galaxy...

View source: R/2025-10-27_JF_R_Galaxy_functions.R

galaxy_history_sizeR Documentation

Galaxy history size Get the disk usage / size of a Galaxy history

Description

The function first tries to read a size/disk_usage field from the history summary endpoint. If that is not present it fetches the history contents and sums dataset sizes (robust to a few different field names used by different Galaxy versions). Results are returned as a data.frame with bytes and a human-readable size.

Usage

galaxy_history_size(
  history_id,
  galaxy_url = "https://usegalaxy.eu",
  include_deleted = FALSE
)

Arguments

history_id

Galaxy history ID.

galaxy_url

Character. Base URL of the Galaxy instance (for example "https://usegalaxy.eu"). If the environment variable GALAXY_URL is set, it takes precedence.

include_deleted

Logical; whether to include deleted datasets when summing (default FALSE)

Value

data.frame with columns history_id, bytes, human_size

Examples


histories <- galaxy_list_histories()
if(nrow(histories > 0)){
  galaxy_history_size(histories$history_id[1])
} else {
  message("No histories found for current user.")
}



GalaxyR documentation built on July 6, 2026, 5:08 p.m.