File: write.arff.Rd

package info (click to toggle)
foreign 0.8.61-1
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 1,560 kB
  • ctags: 863
  • sloc: ansic: 7,501; asm: 4; makefile: 1
file content (42 lines) | stat: -rw-r--r-- 1,398 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
% This file is part of the 'foreign' package for R
% It is distributed under the GPL version 2 or later

\name{write.arff}
\alias{write.arff}
\title{Write Data into ARFF Files}
\description{
  Writes data into Weka Attribute-Relation File Format (ARFF) files.
}
\usage{
write.arff(x, file, eol = "\n", relation = deparse(substitute(x)))
}
\arguments{
  \item{x}{the data to be written, preferably a matrix or data frame.
    If not, coercion to a data frame is attempted.}
  \item{file}{either a character string naming a file, or a connection.
    \code{""} indicates output to the standard output connection.}
  \item{eol}{the character(s) to print at the end of each line (row).}
  \item{relation}{The name of the relation to be written in the file.}
}
\details{
  \code{relation} will be passed through \code{\link{make.names}} before
  writing to the file, in an attempt to it them acceptable to Weka, and
  column names what do not start with an alphabetic character will have
  \code{X} prepended.
  
  However, the references say that ARFF files are ASCII files, and that
  encoding is not enforced.
}
\references{
  Attribute-Relation File Format
  \url{http://www.cs.waikato.ac.nz/~ml/weka/arff.html}\cr
  \url{http://weka.sourceforge.net/wekadoc/index.php/en:ARFF_(3.5.1)}
}  
\seealso{
  \code{\link{read.arff}}
}
\examples{
write.arff(iris, file = "")
}
\keyword{print}
\keyword{file}