I have a set of ChIP-seq peaks for 4 samples. I want to create one file in which the intersected genomic peaks are listed along with how many out of the 4 samples it appeared. I would also like the genomic region of the intersect over multiple samples to have the lowest start and highest end coordinates across the samples. E.g Sample A - Chr 1 349-678 Sample B - Chr 1 328-669 Sample C - Chr 1 330-671 Sample D - Chr 1 351-677
I would like it come back as Chr 1 328-678 and it was in 4 samples. I think the bedtools multiinter is something I can use but there doesn’t seem to be much information on it and also how to do it according to what I want. Can anyone help in what the best way going about this is?