save.tab: Save List of Data Frame or Matrix into CSV File

View source: R/mt_util.R

save.tabR Documentation

Save List of Data Frame or Matrix into CSV File

Description

Save a list of data frame or matrix into a CSV file

Usage

  save.tab(x, filename="temp.csv", firstline="\n")

Arguments

x

A list of data frame or matrix.

filename

A character string for saved file name.

firstline

A string giving some description of the saved file.

Details

This function gives a quick option to save a set of data frame or matrix into a single table file.

Value

No return value, called for side effects.

Author(s)

Wanchang Lin

See Also

write.table

Examples

## Not run: 
data(abr1)
dat <- preproc(abr1$pos[,200:400], method="log10")  
cls <- factor(abr1$fact$class)

tmp <- dat.sel(dat, cls, choices=c("1","2"))
x   <- tmp[[1]]$dat
y   <- tmp[[1]]$cls

fs.method <- c("fs.anova","fs.rf","fs.rfe")
fs.pars   <- valipars(sampling="cv",niter=10,nreps=5)
fs <- feat.mfs(x, y, fs.method, fs.pars)   ## with resampling
names(fs)
fs <- fs[1:3]

## save consistency of feature selection
filename  <- "fs.csv"
firstline <- paste('\nResults of feature selection', sep='')

save.tab(fs, filename, firstline)

## End(Not run)

mt documentation built on June 22, 2024, 12:24 p.m.

Related to save.tab in mt...