BSGenome problem with forgeBSgenomeDataPkg command
2
0
Entering edit mode
pj dias ▴ 60
@pj-dias-4324
Last seen 8.3 years ago

Hi to the Bioconductor community,

I have been in the process of forging many genomes and found that after the upgrade of R to a version like R version 3.2.3 (2015-12-10), the use of the forgeBSgenomeDataPkg command originates a error that does not occur when I use a R version like R version 3.0.2 (2013-09-25).

I leave bellow the output I get when I start to forge a particular genome, with the same seed file, but using different R versions.

Regards,

pj

 

 

R version 3.0.2 (2013-09-25) -- "Frisbee Sailing"
Copyright (C) 2013 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

  Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(BSgenome);
Loading required package: BiocGenerics
Loading required package: parallel

Attaching package: ‘BiocGenerics’

The following objects are masked from ‘package:parallel’:

    clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
    clusterExport, clusterMap, parApply, parCapply, parLapply,
    parLapplyLB, parRapply, parSapply, parSapplyLB

The following object is masked from ‘package:stats’:

    xtabs

The following objects are masked from ‘package:base’:

    anyDuplicated, append, as.data.frame, as.vector, cbind, colnames,
    duplicated, eval, evalq, Filter, Find, get, intersect, is.unsorted,
    lapply, Map, mapply, match, mget, order, paste, pmax, pmax.int,
    pmin, pmin.int, Position, rank, rbind, Reduce, rep.int, rownames,
    sapply, setdiff, sort, table, tapply, union, unique, unlist

Loading required package: IRanges
Loading required package: GenomicRanges
Loading required package: XVector
Loading required package: Biostrings
> forgeBSgenomeDataPkg("/home/pj/Genomas_Features_Make_BSgenome/2_Forge_BSgenome/seed");
Loading required package: Biobase
Welcome to Bioconductor

    Vignettes contain introductory material; view with
    'browseVignettes()'. To cite Bioconductor, see
    'citation("Biobase")', and for packages 'citation("pkgname")'.

Creating package in ./BSgenome.sapa22.YGAP.R1
Saving 'seqlengths' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/seqlengths.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr1.fa' in 'Chr1' object ... DONE
Saving 'Chr1' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr1.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr2.fa' in 'Chr2' object ... DONE
Saving 'Chr2' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr2.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr3.fa' in 'Chr3' object ... DONE
Saving 'Chr3' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr3.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr4.fa' in 'Chr4' object ... DONE
Saving 'Chr4' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr4.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr5.fa' in 'Chr5' object ... DONE
Saving 'Chr5' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr5.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr6.fa' in 'Chr6' object ... DONE
Saving 'Chr6' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr6.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr7.fa' in 'Chr7' object ... DONE
Saving 'Chr7' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr7.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr8.fa' in 'Chr8' object ... DONE
Saving 'Chr8' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr8.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr9.fa' in 'Chr9' object ... DONE
Saving 'Chr9' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr9.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr10.fa' in 'Chr10' object ... DONE
Saving 'Chr10' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr10.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr11.fa' in 'Chr11' object ... DONE
Saving 'Chr11' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr11.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr12.fa' in 'Chr12' object ... DONE
Saving 'Chr12' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr12.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr13.fa' in 'Chr13' object ... DONE
Saving 'Chr13' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr13.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr14.fa' in 'Chr14' object ... DONE
Saving 'Chr14' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr14.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr15.fa' in 'Chr15' object ... DONE
Saving 'Chr15' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr15.rda' ... DONE
Loading FASTA file '/home/pj/Genomas_Features_Make_BSgenome/3_Genome_directory/Chr16.fa' in 'Chr16' object ... DONE
Saving 'Chr16' object to compressed data file './BSgenome.sapa22.YGAP.R1/inst/extdata/Chr16.rda' ... DONE
> sessionInfo()
R version 3.0.2 (2013-09-25)
Platform: x86_64-pc-linux-gnu (64-bit)

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=pt_PT.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=pt_PT.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=pt_PT.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=pt_PT.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] parallel  stats     graphics  grDevices utils     datasets  methods  
[8] base     

other attached packages:
[1] Biobase_2.22.0       BSgenome_1.30.0      Biostrings_2.30.1   
[4] GenomicRanges_1.14.4 XVector_0.2.0        IRanges_1.20.7      
[7] BiocGenerics_0.8.0  

loaded via a namespace (and not attached):
[1] stats4_3.0.2 tools_3.0.2

 

 

 

 

 


R version 3.2.3 (2015-12-10) -- "Wooden Christmas-Tree"
Copyright (C) 2015 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

  Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(BSgenome);
Loading required package: BiocGenerics
Loading required package: parallel

Attaching package: ‘BiocGenerics’

The following objects are masked from ‘package:parallel’:

    clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
    clusterExport, clusterMap, parApply, parCapply, parLapply,
    parLapplyLB, parRapply, parSapply, parSapplyLB

The following objects are masked from ‘package:stats’:

    IQR, mad, xtabs

The following objects are masked from ‘package:base’:

    anyDuplicated, append, as.data.frame, as.vector, cbind, colnames,
    do.call, duplicated, eval, evalq, Filter, Find, get, grep, grepl,
    intersect, is.unsorted, lapply, lengths, Map, mapply, match, mget,
    order, paste, pmax, pmax.int, pmin, pmin.int, Position, rank,
    rbind, Reduce, rownames, sapply, setdiff, sort, table, tapply,
    union, unique, unlist, unsplit

Loading required package: S4Vectors
Loading required package: stats4
Loading required package: IRanges
Loading required package: GenomeInfoDb
Loading required package: GenomicRanges
Loading required package: Biostrings
Loading required package: XVector
Loading required package: rtracklayer
> forgeBSgenomeDataPkg("/home/pj/Genomas_Features_Make_BSgenome/2_Forge_BSgenome/seed");
Error in makeS4FromList("BSgenomeDataPkgSeed", x) :
  some names in 'x' are not valid BSgenomeDataPkgSeed slots (species)
> sessionInfo()
R version 3.2.3 (2015-12-10)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 14.04.4 LTS

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=pt_PT.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=pt_PT.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=pt_PT.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=pt_PT.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats4    parallel  stats     graphics  grDevices utils     datasets
[8] methods   base     

other attached packages:
[1] BSgenome_1.38.0      rtracklayer_1.30.4   Biostrings_2.38.4   
[4] XVector_0.10.0       GenomicRanges_1.22.4 GenomeInfoDb_1.6.3  
[7] IRanges_2.4.8        S4Vectors_0.8.11     BiocGenerics_0.16.1

loaded via a namespace (and not attached):
 [1] XML_3.98-1.4               Rsamtools_1.22.0          
 [3] GenomicAlignments_1.6.3    bitops_1.0-6              
 [5] futile.options_1.0.0       zlibbioc_1.16.0           
 [7] futile.logger_1.4.1        lambda.r_1.1.7            
 [9] BiocParallel_1.4.3         tools_3.2.3               
[11] Biobase_2.30.0             RCurl_1.95-4.8            
[13] SummarizedExperiment_1.0.2
 

bsgenome forge • 1.3k views
ADD COMMENT
0
Entering edit mode
@herve-pages-1542
Last seen 17 hours ago
Seattle, WA, United States

Hi pj,

It's not just your version of R that has changed, but also your Bioconductor version. You've switched from using BioC 2.13, which is more than 2 year old, to using BioC 3.2, which is more recent but still not current. We highly recommend that you update your installation to the most current release (BioC 3.3, released in May this year). We don't support older versions.

Many things can happen in 2 years. In your case, the species field in seed files was renamed common_name (this happened about 1 year ago). Also the commonName() getter should be used now instead of species() on BSgenome objects. Note that special care was taken to preserve backward compatibility with BSgenome packages generated before these changes so there should be no need for your to re-forge the packages you generated in the past with BioC 2.13 / R 3.0.2.

Cheers,

H.

ADD COMMENT
0
Entering edit mode

Hi Hervé,

Thanks for the quick reply.

I upgraded R and Bioconductor to the latest release, in case of R is 3.3.1.

However, when I tried to install BSgenome I got the error

Warning message:
package ‘BSgenome’ is not available (for R version 3.3.1)


Can someone tell me what is the latest R version compatible with BSgenome, so I don't have to install each R version from R-3.2.3 until the latest.

Regards,

pj

PS. I will follow the remarks you made regarding the changes from 2 years from now, "species" field etc, probably the problem lies in those changes.

 

 

ADD REPLY
0
Entering edit mode
pj dias ▴ 60
@pj-dias-4324
Last seen 8.3 years ago

Hi Hervé,

I upgraded R and bioconductor, and the problem resided in the species field have been changed to common_name field.

With this small correction, the genome forging went OK.

Maybe could be a thing to add to the text of the pdf file "How to forge a BSgenome data package", remarking that modification to that seed file field, for those who have a pipeline already in place to forge genomes but are not involved in the development of the BSgenome package (and will miss to notice the change in this field and, most likely, will get the same error).

Nonetheless, great work on the BSgenome package,

Best regards,

pj

ADD COMMENT

Login before adding your answer.

Traffic: 643 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6