SCM

SCM Repository

[matrix] Diff of /pkg/Matrix/man/externalFormats.Rd
ViewVC logotype

Diff of /pkg/Matrix/man/externalFormats.Rd

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 825, Sun Aug 7 15:22:33 2005 UTC revision 1228, Wed Mar 15 17:43:34 2006 UTC
# Line 1  Line 1 
1  \name{externalFormats}  \name{externalFormats}
2    \docType{genericFunction}
3  \alias{readHB}  \alias{readHB}
4  \alias{readMM}  \alias{readMM}
5    \alias{writeHB}
6    \alias{writeMM}
7    \alias{writeHB,dgCMatrix-method}
8    \alias{writeHB,dgTMatrix-method}
9    \alias{writeHB,dsCMatrix-method}
10    \alias{writeHB,dsTMatrix-method}
11    \alias{writeMM,dgCMatrix-method}
12    \alias{writeMM,dgTMatrix-method}
13    \alias{writeMM,dsCMatrix-method}
14    \alias{writeMM,dsTMatrix-method}
15  \title{Read and write external matrix formats}  \title{Read and write external matrix formats}
16  \description{  \description{
17      Read matrices stored in the Harwell-Boeing or MatrixMarket formats.      Read matrices stored in the Harwell-Boeing or MatrixMarket formats
18        or write sparseMatrix objects to one of these formats.
19  }  }
20  \usage{  \usage{
21  readHB(filename)  readHB(file)
22  readMM(filename)  readMM(file)
23    writeHB(obj, file, ...)
24    writeMM(obj, file, ...)
25  }  }
26  \arguments{  \arguments{
27    \item{filename}{the name of the file to read, as a character scalar.   \item{obj}{a real sparse matrix}
28     \item{file}{for \code{writeHB} and \code{writeMM} - the name of the
29       file to be written.  For \code{readHB} and \code{readMM}
30       the name of the file to read, as a character scalar.
31      The names of files storing matrices in the Harwell-Boeing format      The names of files storing matrices in the Harwell-Boeing format
32      usually end in \code{".rua"} or \code{".rsa"}.  Those storing      usually end in \code{".rua"} or \code{".rsa"}.  Those storing
33      matrices in the MatrixMarket format usually end in {".mtx"}.}     matrices in the MatrixMarket format usually end in {".mtx"}.
34    
35       Alternatively, \code{readHB} accepts a connection object.}
36     \item{\dots}{optional additional arguments. Currently none are used in
37       any methods.}
38  }  }
39  \value{  \value{
40    An object that inherits from the \code{"Matrix"} class.    The \code{readHB} and \code{readMM} functions return an object that
41      inherits from the \code{"Matrix"} class.  Methods for the
42      \code{writeHB} and \code{writeMM} generic functions usually return
43      \code{NULL} and, as a side effect, the matrix \code{obj} is written to
44      \code{file} in the Harwell-Boeing format (writeHB)
45      or the MatrixMarket format (writeMM).
46  }  }
47  \references{  \references{
48    \url{http://math.nist.gov/MatrixMarket}    \url{http://math.nist.gov/MatrixMarket}
49    
50      \url{http://www.cise.ufl.edu/research/sparse/matrices}
51    }
52    \examples{
53    str(pores <- readMM(system.file("external/pores_1.mtx",
54                                    package = "Matrix")))
55    str(utm <- readHB(system.file("external/utm300.rua",
56                                   package = "Matrix")))
57    str(lundA <- readMM(system.file("external/lund_a.mtx",
58                                    package = "Matrix")))
59    str(lundA <- readHB(system.file("external/lund_a.rsa",
60                                    package = "Matrix")))
61    \dontrun{
62    ## NOTE: The following examples take quite some time
63    ## ----  even on a fast internet connection:
64    str(sm <-
65     readHB(gzcon(url("http://www.cise.ufl.edu/research/sparse/HBformat/Boeing/msc00726.rsa.gz"))))
66    str(jgl009 <-
67     readMM(gzcon(url("ftp://math.nist.gov/pub/MatrixMarket2/Harwell-Boeing/counterx/jgl009.mtx.gz"))))
68    }
69    data(KNex)
70    writeHB(KNex$mm, "mmHB.rua")
71    writeMM(KNex$mm, "mmMM.mtx")
72  }  }
73  \keyword{IO}  \keyword{IO}
74    \keyword{array}
75  \keyword{algebra}  \keyword{algebra}
76    

Legend:
Removed from v.825  
changed lines
  Added in v.1228

root@r-forge.r-project.org
ViewVC Help
Powered by ViewVC 1.0.0  
Thanks to:
Vienna University of Economics and Business Powered By FusionForge