writeLibText {TargetSearch} | R Documentation

## Save a library object in text format

### Description

This function creates tab delimited text file with library information. The created file can be re-imported with the `ImportLibrary` function.

### Usage

    writeLibText(lib, file)

### Arguments

`lib` | A `tsLib` object. A metabolite library.
`file` | A string naming the output file.

### Author(s)

Alvaro Cuadros-Inostroza

### See Also

`tsLib`, `ImportLibrary`

### Examples

    # get the reference library file
    cdfpath <- file.path(find.package("TargetSearchData"), "gc-ms-data")
    lib.file  <- file.path(cdfpath, "library.txt")

    # Import the reference library
    refLibrary <- ImportLibrary(lib.file)

    # save it to a file
    writeLibText(refLibrary, file="libraryCopy.txt")

[Package TargetSearch version 1.48.0 Index]