reformat_gmt {SCdeconR}R Documentation

Methods to manipulate .gmt files

Description

Reformat, read & write .gmt file.

Usage

reformat_gmt(gmtfile, outputfile, replace = FALSE)

read_gmt(gmtfile)

write_gmt(gmt, outputfile, replace = FALSE)

Arguments

gmtfile

path to a gene set definition file in .gmt format.

outputfile

full path including file name to export reformatted .gmt file.

replace

a logical value indicating whether to replace the output file if it already exists. Default to FALSE.

gmt

a gmt object returned by read_gmt.

Details

reformat_gmt replaces blank spaces within the gene-set names to help string-matching methods in downstream plot functions gsea_sumplot ,gsea_rwplot, gsea_heatmap.

Value

for read_gmt, returns a list object with length equal to the total number of gene sets within the .gmt file. Each list contains three elements: "id", "name", "genes". read_gmt & write_gmt are reimplemented based on functions from ActivePathways package.


[Package SCdeconR version 1.0.0 Index]