The R Project SVN R-packages

Rev

Rev 4530 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 4530 Rev 4558
Line 35... Line 35...
35
{
35
{
36
    CHM_TR chxt = AS_CHM_TR(x);
36
    CHM_TR chxt = AS_CHM_TR(x);
37
    CHM_SP chxs = cholmod_triplet_to_sparse(chxt, chxt->nnz, &c);
37
    CHM_SP chxs = cholmod_triplet_to_sparse(chxt, chxt->nnz, &c);
38
    int tr = asLogical(tri);
38
    int tr = asLogical(tri);
39
    int Rkind = (chxt->xtype != CHOLMOD_PATTERN) ? Real_kind(x) : 0;
39
    int Rkind = (chxt->xtype != CHOLMOD_PATTERN) ? Real_kind(x) : 0;
-
 
40
    R_CheckStack();
40
 
41
 
41
    return chm_sparse_to_SEXP(chxs, 1, 
42
    return chm_sparse_to_SEXP(chxs, 1,
42
			      tr ? ((*uplo_P(x) == 'U') ? 1 : -1) : 0,
43
			      tr ? ((*uplo_P(x) == 'U') ? 1 : -1) : 0,
43
			      Rkind, tr ? diag_P(x) : "",
44
			      Rkind, tr ? diag_P(x) : "",
44
			      GET_SLOT(x, Matrix_DimNamesSym));
45
			      GET_SLOT(x, Matrix_DimNamesSym));
45
}
46
}