Quantifies the area of overlap between two consonance functions, providing a measure of compatibility between two estimates.
curve_overlap(data1, data2, type = "c", plot = TRUE,
title = "Consonance Function Overlap")A list containing:
Estimated area of overlap
Total combined area
Ratio of overlap to total area
Maximum confidence level where intervals overlap
This function computes the overlap between two consonance functions, which provides a measure of how compatible two estimates are with each other. Higher overlap indicates greater compatibility.
The overlap is calculated by finding the intersection of intervals at each confidence level and integrating over the shared region.
curve_compare() for graphical comparison
plot_compare() for visualization
if (FALSE) { # \dontrun{
# Compare two study results
study1 <- curve_from_ratio(1.5, 1.1, 2.0)
study2 <- curve_from_ratio(1.3, 0.9, 1.8)
overlap <- curve_overlap(study1[[1]], study2[[1]])
print(overlap)
} # }