## ----loadlib, echo=TRUE-------------------------------------------------- library(CRISPRseek) library(BSgenome.Hsapiens.UCSC.hg19) library(TxDb.Hsapiens.UCSC.hg19.knownGene) library(org.Hs.eg.db) outputDir <- file.path(getwd(),"CRISPRseekDemo") inputFilePath <- system.file('extdata', 'inputseq.fa', package = 'CRISPRseek') ## ---- helpFun, echo=TRUE, eval=FALSE------------------------------------- # args(offTargetAnalysis) # args(compare2Sequences) # ?offTargetAnalysis # ?compare2Sequences # ?CRISPRseek # browseVignettes('CRISPRseek') ## ------------------------------------------------------------------------ offTargetAnalysis(inputFilePath, BSgenomeName = Hsapiens, chromToSearch ="chrX", txdb = TxDb.Hsapiens.UCSC.hg19.knownGene, orgAnn = org.Hs.egSYMBOL, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ offTargetAnalysis(inputFilePath, findPairedgRNAOnly = TRUE, min.gap = 0, max.gap = 20, BSgenomeName = Hsapiens, chromToSearch ="chrX", txdb = TxDb.Hsapiens.UCSC.hg19.knownGene, orgAnn = org.Hs.egSYMBOL, max.mismatch = 0, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ offTargetAnalysis(inputFilePath, findPairedgRNAOnly = TRUE, min.gap = 0, max.gap = 20, BSgenomeName = Hsapiens, chromToSearch ="chrX", txdb = TxDb.Hsapiens.UCSC.hg19.knownGene, orgAnn = org.Hs.egSYMBOL, max.mismatch = 2, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ offTargetAnalysis(inputFilePath, findgRNAsWithREcutOnly = TRUE, minREpatternSize = 6, overlap.gRNA.positions = c(17, 18), findPairedgRNAOnly = TRUE, min.gap = 0, max.gap = 20, BSgenomeName = Hsapiens, chromToSearch ="chrX", txdb = TxDb.Hsapiens.UCSC.hg19.knownGene, orgAnn = org.Hs.egSYMBOL, max.mismatch = 0, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ offTargetAnalysis(inputFilePath, findgRNAsWithREcutOnly = TRUE, minREpatternSize = 6, overlap.gRNA.positions = c(17, 18), findPairedgRNAOnly = FALSE, BSgenomeName = Hsapiens, chromToSearch ="chrX", max.mismatch = 0, txdb = TxDb.Hsapiens.UCSC.hg19.knownGene, orgAnn = org.Hs.egSYMBOL, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ gRNAFilePath <- system.file('extdata', 'testHsap_GATA1_ex2_gRNA1.fa', package = 'CRISPRseek') offTargetAnalysis(inputFilePath = gRNAFilePath, findPairedgRNAOnly = FALSE, findgRNAs = FALSE, BSgenomeName = Hsapiens, chromToSearch = 'chrX', txdb = TxDb.Hsapiens.UCSC.hg19.knownGene, orgAnn = org.Hs.egSYMBOL, max.mismatch = 2, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ offTargetAnalysis(inputFilePath, chromToSearch = "", outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ inputFile1Path <- system.file("extdata", "rs362331C.fa", package = "CRISPRseek") inputFile2Path <- system.file("extdata", "rs362331T.fa", package = "CRISPRseek") seqs <- compare2Sequences(inputFile1Path, inputFile2Path, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ inputFilePath <- system.file('extdata', 'inputseq.fa', package = 'CRISPRseek') results <- offTargetAnalysis(inputFilePath, annotateExon = FALSE,chromToSearch = "chrX", max.mismatch = 0, BSgenomeName = Hsapiens, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ inputFilePath <- system.file('extdata', 'inputseq.fa', package = 'CRISPRseek') offTargetAnalysis(inputFilePath, annotateExon = FALSE,chromToSearch = "", useEfficacyFromInputSeq = TRUE, max.mismatch = 0, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ results <- offTargetAnalysis(inputFilePath, annotatePaired = FALSE, chromToSearch = "chrX", enable.multicore = TRUE, n.cores.max = 6, annotateExon = FALSE, max.mismatch = 0, BSgenomeName = Hsapiens, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ results <- offTargetAnalysis(inputFilePath, annotatePaired = FALSE, scoring.method = "CFDscore", chromToSearch = "chrX", annotateExon = FALSE, max.mismatch = 2, BSgenomeName = Hsapiens, outputDir = outputDir, overwrite = TRUE) ## ------------------------------------------------------------------------ results <- offTargetAnalysis(inputFilePath, annotatePaired = FALSE, BSgenomeName = Hsapiens, chromToSearch = "chrX", txdb = TxDb.Hsapiens.UCSC.hg19.knownGene, orgAnn = org.Hs.egSYMBOL, max.mismatch = 4, outputDir = outputDir, overwrite = TRUE, PAM.location = "5prime", PAM = "TGT", PAM.pattern = "^T[A|G]N", allowed.mismatch.PAM = 2, subPAM.position = c(1,2))