table_split {TOmicsVis}R Documentation

Table split used for splitting a grouped column to multiple columns.

Description

Table split used for splitting a grouped column to multiple columns.

Usage

table_split(
  data,
  grouped_var = "go_category",
  value_var = "go_term",
  miss_drop = TRUE
)

Arguments

data

Dataframe: GO and KEGG annotation of background genes (1st-col: Genes, 2nd-col: biological_process, 3rd-col: cellular_component, 4th-col: molecular_function, 5th-col: kegg_pathway).

grouped_var

Character: grouped column name. Default: "go_category".

value_var

Character: value column name. Default: "go_term".

miss_drop

Logical: drop missing values or NA values. Default: TRUE, options: TRUE, FALSE.

Value

Table: table split used for splitting a grouped column to multiple columns.

Author(s)

benben-miao

Examples

# 1. Library TOmicsVis package
library(TOmicsVis)

# 2. Use example dataset
data(gene_go_kegg2)
head(gene_go_kegg2)

# 3. Default parameters
res <- table_split(gene_go_kegg2)
head(res)


[Package TOmicsVis version 2.0.0 Index]