makeTxDbFromGFF {GenomicFeatures} | R Documentation

## Make a TxDb object from annotations available as a GFF3 or GTF file

### Description

The `makeTxDbFromGFF` function allows the user to make a TxDb object from transcript annotations available as a GFF3 or GTF file.

### Usage

    makeTxDbFromGFF(file,
                    format=c("auto", "gff3", "gtf"),
                    dataSource=NA,
                    organism=NA,
                    taxonomyId=NA,
                    circ_seqs=NULL,
                    chrominfo=NULL,
                    miRBaseBuild=NA,
                    metadata=NULL,
                    dbxrefTag)

### Arguments

`file` | Input GFF3 or GTF file. Can be a path to a file, or an URL, or a connection object, or a GFF3File or GTFFile object.
`format` | Format of the input file. Accepted values are: `"auto"` (the default) for auto-detection of the format, `"gff3"`, or `"gtf"`. Use `"gff3"` or `"gtf"` only if auto-detection failed.
`dataSource` | A single string describing the origin of the data file. Please be as specific as possible.
`organism` | What is the Genus and species of this organism. Please use proper scientific nomenclature for example: "Homo sapiens" or "Canis familiaris" and not "human" or "my fuzzy buddy". If properly written, this information may be used by the software to help you out later.
`taxonomyId` | By default this value is NA and the organism provided will be used to look up the correct value for this. But you can use this argument to override that and supply your own taxonomy id here (which will be separately validated). Since providing a valid taxonomy id will not require us to look up one based on your organism: this is one way that you can loosen the restrictions about what is and isn't a valid value for the organism.
`circ_seqs` | A character vector to list out which chromosomes should be marked as circular.
`chrominfo` | Data frame containing information about the chromosomes. Will be passed to the internal call to `makeTxDb`. See `?makeTxDb` for more information. Alternatively, can be a Seqinfo object.
`miRBaseBuild` | Specify the string for the appropriate build Information from mirbase.db to use for microRNAs. This can be learned by calling `supportedMiRBaseBuildValues`. By default, this value will be set to `NA`, which will inactivate the `microRNAs` accessor.
`metadata` | A 2-column data frame containing meta information to be included in the TxDb object. See `?makeTxDb` for more information about the format of `metadata`.
`dbxrefTag` | If not missing, the values in the `Dbxref` attribute with the specified tag (like “GeneID”) are used for the feature names.

### Details

`makeTxDbFromGFF` is a convenience function that feeds data from the parsed file to the `makeTxDbFromGRanges` function.

### Value

A TxDb object.

### Author(s)

M. Carlson and H. Pagès

### See Also

- `makeTxDbFromGRanges`, which `makeTxDbFromGFF` is based on, for making a TxDb object from a GRanges object.

- The `import` function in the rtracklayer package (also used by `makeTxDbFromGFF` internally).

- `makeTxDbFromUCSC`, `makeTxDbFromBiomart`, and `makeTxDbFromEnsembl`, for making a TxDb object from online resources.

- The `supportedMiRBaseBuildValues` function for listing all the possible values for the `miRBaseBuild` argument.

- The TxDb class.

- `makeTxDb` for the low-level function used by the `makeTxDbFrom*` functions to make the TxDb object returned to the user.

### Examples

    ## TESTING GFF3
    gffFile <- system.file("extdata","GFF3_files","a.gff3",package="GenomicFeatures")
    txdb <- makeTxDbFromGFF(file=gffFile,
                dataSource="partial gtf file for Tomatoes for testing",
                organism="Solanum lycopersicum")

    ## TESTING GTF, this time specifying the chrominfo
    gtfFile <- system.file("extdata","GTF_files","Aedes_aegypti.partial.gtf",
                           package="GenomicFeatures")
    chrominfo <- data.frame(chrom = c('supercont1.1','supercont1.2'),
                            length=c(5220442, 5300000),
                            is_circular=c(FALSE, FALSE))
    metadata <- data.frame(name="Resource URL",
                           value=paste0("ftp://ftp.ensemblgenomes.org/pub/metazoa/",
                                        "release-13/gtf/aedes_aegypti/"))
    txdb2 <- makeTxDbFromGFF(file=gtfFile,
                 chrominfo=chrominfo,
                 dataSource="ensemblgenomes",
                 organism="Aedes aegypti",
                 metadata=metadata)

[Package GenomicFeatures version 1.39.7 Index]