After the ACME calculation, each probe is associated with a p-value of enrichment. However, one often wants the contiguous regions associated with runs of p-values above a given p-value threshold.

1 | ```
findRegions(x, thresh = 1e-04)
``` |

`x` |
An |

`thresh` |
The p-value threshold |

Runs of p-values above the p-value threshold will be reported as one "region". These can be used for downstream analyses, export to browsers, submitted for transcription factor binding enrichment analyses, etc.

A data frame with these columns:

`Length` |
The length of the region in probes |

`TF` |
Either TRUE or FALSE; TRUE regions represent regions of enrichment while FALSE regions are the regions between the TRUE regions |

`StartInd` |
The starting Index of the region |

`EndInd` |
The ending Index of the region |

`Sample` |
The sample containing the region |

`Chromosome` |
The Chromosome of the region |

`Start` |
The starting basepairof the region |

`End` |
The ending basepair of the region |

`Median` |
The median p-value in the region |

`Mean` |
The mean p-value in the region |

Sean Davis <sdavis2@mail.nih.gov>

1 2 3 4 | ```
data(example.agff)
example.agffcalc <- do.aGFF.calc(example.agff,window=1000,thresh=0.9)
foundregions <- findRegions(example.agffcalc,thresh=0.001)
foundregions[1:6,]
``` |

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.