diff --git a/man/bin_splitter.Rd b/man/bin_splitter.Rd new file mode 100644 index 0000000..5cde8f4 --- /dev/null +++ b/man/bin_splitter.Rd @@ -0,0 +1,52 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/bin_splitter.R +\name{bin_splitter} +\alias{bin_splitter} +\title{Bin Splitter} +\usage{ +bin_splitter( + these_regions = NULL, + qchrom = NULL, + qstart = NULL, + qend = NULL, + bin_size = 1000 +) +} +\arguments{ +\item{these_regions}{The region(s) to be queried. Can be a data frame with +regions with the following columns; chrom, start, end. +Or in a string in the following format chr:start-end.} + +\item{qchrom}{Query chromosome (prefixed or un-prefixed), +Required if `these_regions` is not provided.} + +\item{qstart}{Query start position. Required if `these_regions` is not provided.} + +\item{qend}{Query end position. Required if `these_regions` is not provided.} + +\item{bin_size}{The size of the bins to split the regions into, default is 1000.} +} +\value{ +A data frame with input regions binned into the specified bin size. +} +\description{ +This function takes a region and splits it into bins of a +specified size. +} +\details{ +This function internally calls the purify_regions function to +properly format the incoming regions.Thus, thuis function can accept either a +data frame of regions or individual region coordinates. +} +\examples{ +#Example 1 - Call function with regions specified individually +my_bins = bin_splitter(qchrom = c("chr1", "chr2"), + qstart = c(100, 200), + qend = c(200, 300), + bin_size = 10) + +#Example 2 - Call the funciton with regions from a data frame +my_regions = purify_regions(these_regions = c("chr7:1000-500000", "chr8:50000-7000000")) +these_bins = bin_splitter(these_regions = my_regions, bin_size = 100000) + +}