File: read.matrix.Rd

package info (click to toggle)
tseries 0.10-7-1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 924 kB
  • ctags: 352
  • sloc: fortran: 1,677; ansic: 623; makefile: 66; sh: 22
file content (39 lines) | stat: -rw-r--r-- 1,069 bytes parent folder | download | duplicates (11)
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
\name{read.matrix}
\alias{read.matrix}
\title{Read Matrix Data}
\description{
  Reads a matrix data file.
}
\usage{
read.matrix(file, header = FALSE, sep = "", skip = 0)
}
\arguments{
  \item{file}{the name of the file which the data are to be read from.}
  \item{header}{a logical value indicating whether the file contains the
    names of the columns as its first line.}
  \item{sep}{the field separator character.  Values on each line of the
    file are separated by this character.}
  \item{skip}{the number of lines of the data file to skip before
    beginning to read data.}
}
\details{
  Usually each row of the file represents an observation and each column
  contains a variable.  The first row possibly contains the names of the
  variables (columns).

  \code{read.matrix} might be more efficient than
  \code{\link{read.table}} for very large data sets.
}
\author{A. Trapletti}
\seealso{
  \code{\link{read.table}}.
}
\examples{
x <- matrix(0, 10, 10)
write(x, "test", ncolumns=10)
x <- read.matrix("test")
x
unlink("test")
}
\keyword{file}
\keyword{ts}