makeTxDbPackage() ERROR: values for symbols SOURCEURL are not single strings
Entering edit mode
gtho123 ▴ 40
Last seen 4.1 years ago
New Zealand

I am trying to make a TxDb package from a gff3 file for an organism not available from UNSC.

I can successfully make the TxDb like so:

txdb <- makeTxDbFromGFF(file="file.gff3",
                        dataSource="Organism Genome Project",
                        organism="My organisim")


However when I to make the package using the makeTxDbPackage function like so:

                version = "4.2",
                maintainer="My name <>",
                author="My name <>",
                providerVersion = "4.2")

I get an error:

Error in makeTxDbPackage(txdb, version = "4.2", maintainer = "My name <>",  :   values for symbols SOURCEURL are not single strings

What is the SOURCEURL? Since I am generating the TxDb from a local file I shouldn't need a url and I don't see where to enter one anyway.

I tried creating the original txdb object using the url to the online repository I obtained the gff3 file from and was successful, however when I tried to make the package I got the same error.


Any help appreciated.

genomicfeatures txdb • 723 views
Entering edit mode
Last seen 3 hours ago
United States

It doesn't look like this TxDb was ever considered a candidate for package status, as there isn't a Resource URL in the metadata table. But that's pretty easy to correct. Here is an example, using one of the examples for makeTxDbFromGFF.

## first run the example, to make a couple of TxDb objects

> example("makeTxDbFromGFF")

mTDFGF> gffFile <- system.file("extdata","GFF3_files","a.gff3",package="GenomicFeatures")

mTDFGF> txdb <- makeTxDbFromGFF(file=gffFile,
mTDFGF+             dataSource="partial gtf file for Tomatoes for testing",
mTDFGF+             organism="Solanum lycopersicum")
Import genomic features from the file as a GRanges object ... OK
Prepare the 'metadata' data frame ... OK
Make the TxDb object ... OK

mTDFGF> ## TESTING GTF, this time specifying the chrominfo
mTDFGF> gtfFile <- system.file("extdata","GTF_files","Aedes_aegypti.partial.gtf",
mTDFGF+                        package="GenomicFeatures")

mTDFGF> chrominfo <- data.frame(chrom = c('supercont1.1','supercont1.2'),
mTDFGF+                         length=c(5220442, 5300000),
mTDFGF+                         is_circular=c(FALSE, FALSE))

mTDFGF> txdb2 <- makeTxDbFromGFF(file=gtfFile,
mTDFGF+              chrominfo=chrominfo,
mTDFGF+              dataSource=paste("",
mTDFGF+                               "release-13/gtf/aedes_aegypti/",sep=""),
mTDFGF+              organism="Aedes aegypti")
Import genomic features from the file as a GRanges object ... OK
Prepare the 'metadata' data frame ... OK
Make the TxDb object ... OK

## try to make a package with the second txdb
> makeTxDbPackage(txdb2, version = "0.0.1", maintainer = "me <>", author = "me", pkgname = "whatevs", providerVersion = "0.0.1")
Error in makeTxDbPackage(txdb2, version = "0.0.1", maintainer = "me <>",  :
  values for symbols SOURCEURL are not single strings

I get the same error as you, which is pretty cryptic. But let's fix it anyway, shall we?

## Make a connection to the db
> con <- dbconn(txdb2)

## insert a Resource URL entry in the metadata table,
## pointing to the ftp site where the data were procured
> DBI::dbGetQuery(con, "INSERT INTO metadata VALUES ('Resource URL', '');")

## Make the package
> makeTxDbPackage(txdb2, version = "0.0.1", maintainer = "me <>", author = "me", pkgname = "whatevs", providerVersion = "0.0.1")
Creating package in ./whatevs
TxDb object:
# Db type: TxDb
# Supporting package: GenomicFeatures
# Data source:
# Organism: Aedes aegypti
# Taxonomy ID: 7159
# miRBase build ID: NA
# Genome: NA
# transcript_nrow: 105
# exon_nrow: 402
# cds_nrow: 381
# Db created by: GenomicFeatures package from Bioconductor
# Creation time: 2016-11-29 09:54:12 -0500 (Tue, 29 Nov 2016)
# GenomicFeatures version at creation time: 1.26.0
# RSQLite version at creation time: 1.0.0
# Resource URL:

And now that can be installed as per usual. We should change the API for makeTxDbFromGFF to natively accommodate building a package from the resulting TxDb, but that won't occur before the next release (changes to the API for release packages are verboten), so for now you will have to fix your TxDb by hand.


Login before adding your answer.

Traffic: 237 users visited in the last hour
Help About
Access RSS

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

Powered by the version 2.3.6