export: Export data from R

exportR Documentation

Export data from R

Description

Export data from R

Usage

export(object, con, ...)

## S4 method for signature 'TxToGene,character'
export(object, con, ...)

Arguments

object

Object.

con

character(1) or connection. Data connection. Use character(1) to represent a file path.

...

Additional arguments.

Details

The TxToGene method automatically disables writing of column names, which is the intended input format for tximport.

Value

Invisible character or list of file paths.

Note

Updated 2023-09-20.

Examples

object <- S4Vectors::DataFrame(
    "txId" = c(
        "tx0001",
        "tx0002",
        "tx0003",
        "tx0004"
    ),
    "geneId" = c(
        "gene0001",
        "gene0001",
        "gene0002",
        "gene0002"
    )
)
object <- TxToGene(object)
con <- file.path(AcidBase::tempdir2(), "tx2gene.csv")
export(object = object, con = con)
x <- readLines(con, n = 4L)
print(x)
AcidBase::unlink2(con)

acidgenomics/AcidGenomes documentation built on Dec. 10, 2023, 10:35 p.m.