You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@systemml.apache.org by "Deron Eriksson (JIRA)" <ji...@apache.org> on 2016/05/03 23:31:12 UTC

[jira] [Commented] (SYSTEMML-373) as.scalar vs castAsScalar

    [ https://issues.apache.org/jira/browse/SYSTEMML-373?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15269631#comment-15269631 ] 

Deron Eriksson commented on SYSTEMML-373:
-----------------------------------------

This issue has been addressed by SYSTEMML-647 and SYSTEMML-648. I will therefore close this issue.

> as.scalar vs castAsScalar
> -------------------------
>
>                 Key: SYSTEMML-373
>                 URL: https://issues.apache.org/jira/browse/SYSTEMML-373
>             Project: SystemML
>          Issue Type: Improvement
>          Components: APIs, Documentation
>            Reporter: Deron Eriksson
>            Priority: Minor
>
> Currently, as.scalar() and castAsScalar() both allow a matrix element value to be cast to a scalar, as in this example:
> {code}
> A = matrix("1 2 3 4", rows=2, cols=2)
> print(as.scalar(A[1,1]))
> print(castAsScalar(A[1,1]))
> {code}
> The as.scalar() function is documented in the DML Language Reference. The castAsScalar() function is not documented in the DML Language Reference.
> Which function is the preferred method to use to cast a matrix element to a scalar value?
> Should both functions exist, or should only one function exist?
> If castAsScalar() should continue to exist, the DML Language Reference should be updated to include it.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)