writeARFF: Write ARFF data.frame to ARFF file.

Description

Internally uses write.table and is therefore not much faster than RWeka's write.arff. Moreover, for large data (> 1e6 rows) the date frame is written out in chunks of 1e6 lines to speed up the write process.

Usage

1
2
writeARFF(x, path, overwrite = FALSE, chunk.size = 1e+06,
  relation = deparse(substitute(x)))

Arguments

x

[data.frame]
Data to write to disk.

path

[character(1)]
Path to ARFF file with write access. Existing files will not be overwritten unless overwrite is TRUE.

overwrite

[logical(1)]
Should path be overwritten if it already exists? Default is FALSE.

chunk.size

[integer(1)]
Large datesets are splitted before writing out to file into chunks of size chunk.size. Default is 1e6.

relation

[character(1)]
Name of the relation in the ARFF file. Default is to guess it from the object name.

Value

Nothing.

Note

Logical columns in R are converted to categorical attributes in ARFF with levels “TRUE” and “FALSE”.

Examples

1
# see readARFF

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.