This function calculates appropriate y-axis limits for link/arc tracks based on the maximum genomic distance span and height factor. This ensures curves are not clipped and provides consistent spacing for multi-track plots.
Examples
if (FALSE) { # \dontrun{
df <- data.frame(
start1 = c(1000, 2000, 3000),
start2 = c(5000, 6000, 7000)
)
ylim <- calculate_link_ylim(df, height_factor = 0.15, direction = "down")
} # }