slice_definition: Define chromosomal regions for screening

Description Usage Arguments Examples

View source: R/definition_slice.R

Description

Define overlapping loci starting and ending positions for wavelet screening analysis

Usage

1
slice_definition(bp, Loci_size = 1e+06, thresh = 10000, Chr = NA)

Arguments

bp

vector of the observed based pair positions in a chromosome

Loci_size

size of the defined loci, limited by thresh size gaps on ends. Slices smaller than Loci_size will be skipped.

thresh

maximal distance between two SNP within a locus. E.g., 10000

Chr

the chromosome's number where the slicing is made. By default set as NA

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## Not run: 
Loci_size=1000000
thresh=10000
temp <- runif(n = 50000,min=1,max=10050)
for (i in 2:length(temp))
{
 temp[i] <- temp[i]+temp[i-1]
}
bp <- temp
df <-slice_definition(bp=bp,Loci_size=Loci_size,thresh = thresh ,Chr=5)
head(df)

## End(Not run)

william-denault/WaveletScreaming documentation built on Jan. 23, 2021, 12:34 p.m.