jon
jon

Reputation: 11366

BSgenome data loading problem for applying in biostrings package function

I installed BSgenome seems working but I am not able to load library. The following code are from Biostrings package

     > require(BSgenome) 
     > require(Biostrings)      
    >    library(BSgenome.Dmelanogaster.UCSC.dm3)
    Error in library(BSgenome.Dmelanogaster.UCSC.dm3) : 
      there is no package called 'BSgenome.Dmelanogaster.UCSC.dm3'
    >   subject <- Dmelanogaster$chr3R
    Error: object 'Dmelanogaster' not found
    >   Lpattern <- "AGCTCCGAG"
    >   Rpattern <- "TTGTTCACA"
    >   matchLRPatterns(Lpattern, Rpattern, 500, subject) # 1 match
    Error in function (classes, fdef, mtable)  : 
      unable to find an inherited method for function "matchLRPatterns", for signature "standardGeneric"

I will appreciate your help. Can you try in your computer to see if this works for your? what could be potential problem.

Upvotes: 1

Views: 859

Answers (1)

SHRram
SHRram

Reputation: 4227

Thanks to Roman Lustrik the following codes works:

source("bioconductor.org/biocLite.R";) 
biocLite("BSgenome.Dmelanogaster.UCSC.dm3") 
library(BSgenome.Dmelanogaster.UCSC.dm3) 
subject <- Dmelanogaster$chr3R 
Lpattern <- "AGCTCCGAG" 
Rpattern <- "TTGTTCACA" 
matchLRPatterns(Lpattern, 
Rpattern, 500, subject) # 1 match 

Upvotes: 1

Related Questions