
Comprehensive detection performance analysis with summary and plots
Source:R/1.6_function_walks_detections.R
analyze_detection_performance.Rd
Performs complete analysis of detection performance from fish track simulations, including statistical summaries and visualization plots. This is a convenience function that combines calculation, printing, and plotting in one call.
Arguments
- simulation_results
List output from
simulate_fish_tracks
containing tracks and station_detections data frames.- create_plots
Logical. Whether to generate and display visualization plots. Default is TRUE.
Value
A list containing:
- statistics
Complete detection statistics from
calculate_detection_summaries
- plots
List of ggplot2 objects from
plot_detection_rates
(if create_plots = TRUE)
Returns NULL if no detection data is available.
Details
This function provides a complete workflow for detection analysis:
Calculates detection performance statistics
Prints formatted summary report to console
Creates and displays visualization plots (optional)
Returns all results for further analysis
The function is designed for quick analysis and reporting of receiver array performance, making it easy to evaluate different system configurations.
Examples
if (FALSE) {
# Complete analysis with plots
analysis <- analyze_detection_performance(fish_simulation)
# Access overall detection rate
overall_rate <- analysis$statistics$overall$detection_percentage
# Access individual plots
path_plot <- analysis$plots$by_path
station_plot <- analysis$plots$by_station
distribution_plot <- analysis$plots$distribution
# Analysis without plots (faster)
stats_only <- analyze_detection_performance(fish_simulation, create_plots = FALSE)
}