% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/thoroughBed.R
\docType{methods}
\name{thoroughBed,ANY,LibraryGroupList-method}
\alias{thoroughBed,ANY,LibraryGroupList-method}
\alias{thoroughBed}
\alias{thoroughBed,thoroughBed-LibraryGroupList-method}
\title{thoroughBed -- function to merge chromosomes from libraries that have the same strand states}
\usage{
\S4method{thoroughBed}{ANY,LibraryGroupList}(bamFileList, relatedLibList,
  qual = 10, pairedEnd = TRUE, rmdup = TRUE, verbose = TRUE)
}
\arguments{
\item{bamFileList}{vector containing the location of the bams file to be read}

\item{relatedLibList}{list where each element contains all library names that show similar strand pattern. The product of findSimilarLibraries}

\item{qual}{Mapping quality threshold. Default is 10}

\item{pairedEnd}{Whether the bam files being read are in paired end format. Default is TRUE. Note,
since paired reads will be the same direction, only first mate read of pair is used in output to reduce file size}

\item{rmdup}{Logical as to whether to remove duplicate reads within each library. Default is TRUE.}

\item{verbose}{prints messages to the terminal (default is TRUE)}
}
\value{
a GRanges object comprising merged directional reads from all libraries in relatedLibList.
}
\description{
thoroughBed -- function to merge chromosomes from libraries that have the same strand states
}
\examples{
#Get a list of BAM files containing libraries for cells from the same organism, aligned to the same genome
#In this case these are the example BAM files provided with the package (hence the call to system.file);
data("exampleLibList")


library(BiocParallel)

example.dir <- file.path(system.file(package='contiBAIT'), 'extdata')

exampleRange <- thoroughBed(example.dir, exampleLibList)

show(exampleRange)
}
