Description Details Note Author(s) See Also Examples
Implements classes and methods for large-scale SNP enrichment analysis (e.g. SNPs associated with genes expression in a GWAS signal).
Package: | snpEnrichment |
Title: | SNPs enrichment analysis |
Author: | Mickael Canouil |
Contributor: | Loic Yengo |
Maintainer: | Mickael Canouil |
License: | GPL (>= 2) |
Depends: | R (>= 3.0.0), methods |
Suggests: | grid, ggplot2 |
Imports: | parallel, snpStats |
URL: | https://github.com/mcanouil/snpEnrichment |
Encoding: | UTF-8 |
Internal data management in 'snpEnrichment' use RefSNP (rs) IDs.
Mickael Canouil mickael.canouil@good.ibl.fr
Overview : snpEnrichment-package
Classes : Enrichment
, Chromosome
, EnrichSNP
Methods : plot
, reSample
, getEnrichSNP
, excludeSNP
, compareEnrichment
,
enrichment
, is.enrichment
, chromosome
, is.chromosome
Functions : initFiles
, writeLD
, readEnrichment
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 | ###################
### 1. Prepare data
## Not run: snpInfoDir <- system.file("extdata/snpInfo",
package = "snpEnrichment")
signalFile <- system.file("extdata/Signal/toySignal.txt",
package = "snpEnrichment")
initFiles(pattern = "Chrom", snpInfoDir, signalFile, mc.cores = 1)
writeLD(pattern = "Chrom", snpInfoDir, signalFile,
ldDir = NULL, ldThresh = 0.8, depth = 1000,
mc.cores = 1)
## End(Not run)
################
### 2. Read data
## Not run: snpListDir <- system.file("extdata/List",
package = "snpEnrichment")
data(transcript)
transcriptFile <- transcript
toyData <- readEnrichment(pattern = "Chrom", signalFile,
transcriptFile, snpListDir,
snpInfoDir, distThresh = 1000,
sigThresh = 0.05, LD = TRUE,
ldDir = NULL, mc.cores = 1)
toyData
## End(Not run)
######################
### 3. Compute results
## Not run: reSample(object = toyData,
nSample = 10,
empiricPvalue = TRUE,
MAFpool = c(0.05, 0.10, 0.2, 0.3, 0.4, 0.5),
mc.cores = 1,
onlyGenome = TRUE)
## End(Not run)
#######################
### 4. Further analysis: Exclude SNP from original list.
## Not run: excludeFile <- c(
"rs4376885", "rs17690928", "rs6460708", "rs13061537", "rs11769827",
"rs12717054", "rs2907627", "rs1380109", "rs7024214", "rs7711972",
"rs9658282", "rs11750720", "rs1793268", "rs774568", "rs6921786",
"rs1699031", "rs6994771", "rs16926670", "rs465612", "rs3012084",
"rs354850", "rs12803455", "rs13384873", "rs4364668", "rs8181047",
"rs2179993", "rs12049335", "rs6079926", "rs2175144", "rs11564427",
"rs7786389", "rs7005565", "rs17423335", "rs12474102", "rs191314",
"rs10513168", "rs1711437", "rs1992620", "rs283115", "rs10754563",
"rs10851727", "rs2173191", "rs7661353", "rs1342113", "rs7042073",
"rs1567445", "rs10120375", "rs550060", "rs3761218", "rs4512977"
)
# OR
excludeFile <- system.file("extdata/Exclude/toyExclude.txt",
package = "snpEnrichment")
toyData_exclude <- excludeSNP(toyData, excludeFile, mc.cores = 1)
# Warning: compareEnrichment is in development!!
compareResults <- compareEnrichment(object.x = toyData,
object.y = toyData_exclude,
pattern = "Chrom",
nSample = 10,
empiricPvalue = TRUE,
mc.cores = 1,
onlyGenome = TRUE)
## End(Not run)
####################
### 5. Watch results
## Not run: show(toyData)
print(toyData)
head(getEnrichSNP(toyData, type = "xSNP"))
show(toyData_exclude)
print(toyData_exclude)
head(getEnrichSNP(toyData_exclude, type = "eSNP"))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.