# SCM Repository

[matrix] Diff of /pkg/man/band.Rd
 [matrix] / pkg / man / band.Rd

# Diff of /pkg/man/band.Rd

revision 1452, Sat Aug 26 18:24:13 2006 UTC revision 1453, Sun Aug 27 16:16:35 2006 UTC
# Line 16  Line 16
16  \alias{tril,lsCMatrix-method}  \alias{tril,lsCMatrix-method}
17  \alias{triu,dsCMatrix-method}  \alias{triu,dsCMatrix-method}
18  \alias{triu,lsCMatrix-method}  \alias{triu,lsCMatrix-method}
19    \alias{band,ddenseMatrix-method}
20    \alias{tril,ddenseMatrix-method}
21    \alias{triu,ddenseMatrix-method}
22  %  %
23  \alias{band}  \alias{band}
24  \alias{tril}  \alias{tril}
# Line 55  Line 58
58      \item{x = "TsparseMatrix"}{method for sparse matrices in triplet format.}      \item{x = "TsparseMatrix"}{method for sparse matrices in triplet format.}
59      \item{x = "RsparseMatrix"}{method for compressed, sparse,      \item{x = "RsparseMatrix"}{method for compressed, sparse,
60        row-oriented matrices.}        row-oriented matrices.}
61        \item{x = "ddenseMatrix"}{method for dense numeric matrices,
62          including packed numeric matrices.}
63    }    }
64  }  }
65  \examples{  \examples{
# Line 68  Line 73
73  tril(mm, -1)    # strict lower triangle  tril(mm, -1)    # strict lower triangle
74  triu(mm,  1)    # strict upper triangle  triu(mm,  1)    # strict upper triangle
75  band(mm, -1, 2) # general band  band(mm, -1, 2) # general band
76    (m5 <- Matrix(rnorm(25), nc = 5))
77    tril(m5)        # lower triangle
78    tril(m5, -1)    # strict lower triangle
79    triu(m5, 1)     # strict upper triangle
80    band(m5, -1, 2) # general band
81    (m65 <- Matrix(rnorm(30), nc = 5))  # not square
82    triu(m65)       # result in not dtrMatrix unless square
83    (sm5 <- crossprod(m65)) # symmetric
84    band(sm5, -1, 1)# symmetric band preserves symmetry property
85  \dontshow{ ## this uses special methods  \dontshow{ ## this uses special methods
86  (x.x <- crossprod(mm))  (x.x <- crossprod(mm))
87  tril(x.x)  tril(x.x)

Legend:
 Removed from v.1452 changed lines Added in v.1453