parse.gmt {cmapR} | R Documentation

## Read a GMT file and return a list

### Description

Read a GMT file and return a list

### Usage

    parse.gmt(...)

    parse_gmt(fname)

### Arguments

`...` | arguments passed on to `parse_gmt`
`fname` | the file path to be parsed

### Details

`parse_gmt` returns a nested list object. The top level contains one list per row in `fname`. Each of these is itself a list with the following fields: - `head`: the name of the data (row in `fname`) - `desc`: description of the corresponding data - `len`: the number of data items - `entry`: a vector of the data items

### Value

a list of the contents of `fname`. See details.

### See Also

Visit http://clue.io/help for details on the GMT file format

Other CMap parsing functions: `lxb2mat()`, `parse.gmx()`, `parse.grp()`, `write_gmt()`, `write_grp()`

### Examples

    gmt_path <- system.file("extdata", "query_up.gmt", package="cmapR")
    gmt <- parse_gmt(gmt_path)
    str(gmt)

[Package cmapR version 1.6.0 Index]