-
|
Using the mathjs command line tool: That is surprising. In other tools, like MATLAB and Python Numpy, that slicing would give you a column, (Corrections about my use of terminology, or anything else, are very welcome.) |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
|
Hi, this is a good place to read about slicing. https://mathjs.org/docs/expressions/syntax.html#matrices Regarding what you are describing, it's something that currently happens only for scalar results. a = [[1,2],[3,4]]
a[1, 1] # 1
a[1, :] # [[1, 2]]Some relevant discussions: July 26 2022 #2344 In July 20 2023 at #2994 it was stated that
In July 24 2023 at
I think there is an agreement with what you describe, just not implemented yet. |
Beta Was this translation helpful? Give feedback.
-
|
Thanks @dvd101x |
Beta Was this translation helpful? Give feedback.
Hi, this is a good place to read about slicing.
https://mathjs.org/docs/expressions/syntax.html#matrices
https://mathjs.org/docs/datatypes/matrices.html#getting-or-replacing-subsets
https://mathjs.org/docs/reference/functions/subset.html
Regarding what you are describing, it's something that currently happens only for scalar results.
Some relevant discussions:
July 26 2022 #2344
In July 20 2023 at #2994 it was stated that