Description Usage Arguments Details Value Author(s) References See Also Examples
View source: R/across_genome.r
Apply given function to relatedness at sliding genomic windows
1 2 |
bed |
A |
FUN |
Function to apply to relatedness of individulas at genomic windows. Argument function must be a relatedness matrix. |
relatedness |
Function to compute relatedness matrix at genomic windows. Argument function must be a bed.matrix. |
windows |
Numerical value defined length of genomic windows |
sliding |
Increment length value of sliding genomic windows |
unit |
Distance unit in |
map |
Recombinaison map. Must be |
centromere |
Optional |
LD.thin |
Distance unit in |
thread |
Number of thread used by |
Compute the genetic relatedness and apply given function(s) for all sliding windows of given length windows
in increments of sliding
.
A data.frame (one line by genomic region) with columns :
chr
, start
end end
defining genomic region localisation
index.start
end index.end
defining first and last SNP index inluded in genomic region
recombi_snps
, recombinaison rate estimated on SNPs included in x
defining genomic region
recombi_region
, mean recombinaison rate on genomic region
centro
, logical
, TRUE
if region overlapping a centromere
num
, number of SNPs in genomic region
LD
end LD_sd
, mean and standard deviation of LD in genomic region
maf
end maf_sd
, mean and standard deviation of maf in genomic region
H
end H_sd
, mean and standard deviation of Heterogosity in genomic region
Hz
end Hz_sd
, mean and standard deviation of heterozygous individuals proportion in genomic region
Claire Dandine-Roulland
Laurent, R and Chaix, R, 2012, MHC-dependent mate choice in humans: Why genomic patterns from the HapMap European American dataset support the hypothesi, BioEssays 34(4), 267-271
app.pairs
, app.unpairs
, zscore
1 2 3 4 5 6 7 8 9 | # load chr2 data set (~10k SNPs in low LD)
x <- read.bed.matrix( system.file("extdata", "chr2.bed", package="gaston") )
# Compute Rousset Relationship Matrix
relatedness <- function(x) Rousset(x)$Rousset
fun <- function(app) app.pairs(app, x@ped$population, mean)
# Across the genome
head(app.genome(x, fun, relatedness, windows=2000, sliding=500, unit="bases", thread=2))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.