line_clean: Filter out comments and empty lines

View source: R/learn.R

line_cleanR Documentation

Filter out comments and empty lines

Description

Remove the lines start with # or without any information.

Usage

line_clean(lines = NULL, file = NULL)

Arguments

lines

a vector of character strings. The strings are containing the lines of template file. If the file parameter is NULL, this parameter should be set.

file

a character specifying the template file path. If this parameter is setted, the lines parameter will be replaced.

Value

a vector of character strings

Examples

strs <- c("#comment","DATA")
line_clean(lines=strs)

itol.toolkit documentation built on Nov. 18, 2023, 5:11 p.m.