Learn R Programming

Mergeomics (version 1.0.0)

tool.read: Read a data frame from a file

Description

tool.read reads contents of given input file.

Usage

tool.read(file, vars = NULL)

Arguments

file
file name to be read
vars
if we want to read particular attributes (columns) from the input file, we need to specify names of these attributes within list vars (attribute names can be e.g. MODULE, GENE, LOCUS, etc.)

Value

dat
data frame including content of the given file. If vars is specified, only the listed columns inside the vars list will be returned.

Details

All lines with NAs are excluded.

Examples

Run this code
## read the network file as an example:
net.info <- tool.read(system.file("extdata","network.mouseliver.mouse.txt", 
package="Mergeomics"))
dim(net.info)
names(net.info)

Run the code above in your browser using DataLab