% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils-benchmark.R
\name{plot_gsea_memory}
\alias{plot_gsea_memory}
\title{Plot GSEA Benchmark Memory Curve}
\usage{
plot_gsea_memory(aligned_data, highlight_phases = TRUE)
}
\arguments{
\item{aligned_data}{Aligned data frame returned by align_benchmark_data}

\item{highlight_phases}{Whether to color by phase, default TRUE}
}
\value{
A ggplot object
}
\description{
Generates a standard memory usage curve plot for publication.
}
\examples{
# Build a small synthetic aligned-data frame (mimics the output of
# align_benchmark_data() without needing an external CSV or GseaRes object).
syn <- data.frame(
  timestamp_ms = seq(0, 20000, by = 1000),
  rss_mb = c(120, 150, 220, 280, 310, 330, 340, 335, 320, 305,
             290, 270, 255, 245, 240, 235, 230, 225, 220, 215, 210),
  relative_sec = seq(0, 20, by = 1),
  phase = c(rep("startup", 4), rep("core_compute", 12), rep("cleanup", 5))
)
attr(syn, "gsea_info") <- list(duration_sec = 20, workers = 2)
class(syn) <- c("GseaBenchmarkAligned", "data.frame")
plot_gsea_memory(syn)
plot_gsea_memory(syn, highlight_phases = FALSE)
}
