SCM

SCM Repository

[matrix] Diff of /pkg/tests/matr-exp.R
ViewVC logotype

Diff of /pkg/tests/matr-exp.R

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

revision 538, Thu Feb 10 13:50:27 2005 UTC revision 561, Fri Feb 18 19:24:43 2005 UTC
# Line 5  Line 5 
5    
6  ## checking;  'show' is for convenience of the developer  ## checking;  'show' is for convenience of the developer
7  assert.EQ.mat <- function(M, m, tol = if(show) 0 else 1e-15, show=FALSE) {  assert.EQ.mat <- function(M, m, tol = if(show) 0 else 1e-15, show=FALSE) {
8      if(show) all.equal(as(M, "matrix"), m, tol = tol)      ## temporary fix for R-2.0.1
9      else stopifnot(all.equal(as(M, "matrix"), m, tol = tol))      MM <- as(M, "matrix")
10        attr(MM, "dimnames") <- NULL
11        if(show) all.equal(MM, m, tol = tol)
12        else stopifnot(all.equal(MM, m, tol = tol))
13  }  }
14  ## The relative error typically returned by all.equal:  ## The relative error typically returned by all.equal:
15  relErr <- function(target, current)  relErr <- function(target, current)

Legend:
Removed from v.538  
changed lines
  Added in v.561

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