plot_2d_volume {ChestVolume}R Documentation

Plot Volume Changes by Segment Over Time

Description

This function generates a ggplot to display the volume changes by segment over time. It creates a line plot with each segment's volume on the y-axis and the timeframe on the x-axis.

Usage

plot_2d_volume(
  volume_data,
  segment_names = "Segment",
  title = "Volume Change by Segment"
)

Arguments

volume_data

A data frame with volume measurements, one column per segment, and a "frame" column for time.

segment_names

Column that contain name of segment to plot

title

Optional plot title.

Value

A ggplot object showing volume changes by segment over time.

Examples

# Example usage with random volume data
set.seed(123)
volume_data <- data.frame(
  Timeframe = 1:100,
  Volume = runif(100, min = 100, max = 150),
  Segment = 'UL'
)

plot_2d_volume(volume_data, segment_names = 'Segment')


[Package ChestVolume version 1.0.1 Index]