SCM

SCM Repository

[matrix] Diff of /pkg/src/dgTMatrix.c
ViewVC logotype

Diff of /pkg/src/dgTMatrix.c

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

revision 534, Tue Feb 8 08:59:31 2005 UTC revision 582, Mon Feb 28 18:15:21 2005 UTC
# Line 15  Line 15 
15          *xi = INTEGER(islot);          *xi = INTEGER(islot);
16    
17      if (length(xslot) != nnz || length(jslot) != nnz)      if (length(xslot) != nnz || length(jslot) != nnz)
18          return mkString("lengths of slots i, j, and x must match");          return mkString(_("lengths of slots i, j, and x must match"));
19      if (length(dimslot) != 2)      if (length(dimslot) != 2)
20          return mkString("slot Dim must have length 2");          return mkString(_("slot Dim must have length 2"));
21      nrow = dims[0]; ncol = dims[1];      nrow = dims[0]; ncol = dims[1];
22      for (j = 0; j < nnz; j++) {      for (j = 0; j < nnz; j++) {
23          if (xi[j] < 0 || xi[j] >= nrow)          if (xi[j] < 0 || xi[j] >= nrow)
24              return mkString("all row indices must be between 0 and nrow-1");              return mkString(_("all row indices must be between 0 and nrow-1"));
25          if (xj[j] < 0 || xj[j] >= ncol)          if (xj[j] < 0 || xj[j] >= ncol)
26              return mkString("all column indices must be between 0 and ncol-1");              return mkString(_("all column indices must be between 0 and ncol-1"));
27      }      }
28      return ScalarLogical(1);      return ScalarLogical(1);
29  }  }

Legend:
Removed from v.534  
changed lines
  Added in v.582

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