R/getCountsInWindow.R

Defines functions getCountsInWindow

Documented in getCountsInWindow

getCountsInWindow <-
function(events, startE, endE, windowSize=10000, sorted=FALSE) {
	histBreaks = seq(from=startE, to=endE, by=windowSize)
	if(tail(histBreaks, 1) != endE)
		histBreaks = c(histBreaks, endE)
	countsWindow = hist(events, breaks=histBreaks, right=FALSE, plot=FALSE)$counts
	return(countsWindow)
}

Try the SeqCNVCBS package in your browser

Any scripts or data that you put into this service are public.

SeqCNVCBS documentation built on May 2, 2019, 6:51 p.m.