Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions docs/datatypes/matrices.md
Original file line number Diff line number Diff line change
Expand Up @@ -212,19 +212,19 @@ const c = [[[0, 1, 2], [3, 4, 5]], [[6, 7, 8], [9, 10, 11]]]
math.size(c) // Array, [2, 2, 3]
```

Note that the dimensions themselves do not have a meaning attached.
When creating and printing a two-dimensional matrix, the first dimension is
normally rendered as the _column_, and the second dimension is rendered as
the _row_. For example:
Note that the dimensions themselves do not have a meaning attached.
When creating and printing a two-dimensional matrix, the first dimension is
normally rendered as the _row_, and the second dimension is rendered as
the _column_. For example:

```js
console.table(math.zeros([2, 4]))
// 0 0 0 0
// 0 0 0 0
```

If you have a matrix where the first dimension means `x` and the second
means `y`, this will look confusing since `x` is printed as _column_
If you have a matrix where the first dimension means `x` and the second
means `y`, this will look confusing since `x` is printed as _column_
(vertically) and `y` as _row_ (horizontally).

## Non-rectangular arrays
Expand Down
Loading