# The following array must contain a list of proTRAC output folders. # Listed proTRAC runs must base on the same genome. Otherwise, # merging cluster coordinates makes no sense! @proTRAC_folders= ( "proTRAC_sRNA-ACR-140_preproc.map.weighted-10000-1000-b-0_2024y6m20d14h55m16s", "proTRAC_sRNA-ACR-145_preproc.map.weighted-10000-1000-b-0_2024y6m20d15h1m25s", "proTRAC_sRNA-ACR-150_preproc.map.weighted-10000-1000-b-0_2024y6m20d15h8m8s", "proTRAC_sRNA-ACR-173_preproc.map.weighted-10000-1000-b-0_2024y6m20d15h13m58s", "proTRAC_sRNA-ACR-178_preproc.map.weighted-10000-1000-b-0_2024y6m20d15h19m33s", ); $min_dist=10000; # This is the minimum distance between two independent piRNA clusters. Clusters closer to each other will be merged. $output_table="merged_cluster_coordinates.txt"; $|=1; %clusters=(); foreach$folder(@proTRAC_folders) { open(TABLE,"$folder/results.table")||print"\nCannot open $folder/results.table.\n$!\n\n"; while(