Matrix transposition: Difference between revisions
m
→{{header|Stata}}
(+Stata) |
|||
Line 3,085:
=={{header|Stata}}==
Stata matrices are always real, so there is no ambiguity about the transpose operator. Mata matrices, however, may be real or complex. The transpose operator is actually a conjugate transpose, but there is also a '''[https://www.stata.com/help.cgi?mf_transposeonly transposeonly()]''' function.
=== Stata matrices ===
<lang stata>. mat a=1,2,3\4,5,6
Line 3,104 ⟶ 3,106:
=== Mata ===
<lang stata>: a=1,
: a
1 2
+
1 | 1
+-------------+▼
: a'
+
1 |
2 |
+---------+</lang>▼
: transposeonly(a)
1
1 | 1 |
2 | 1i |
=={{header|Tcl}}==
With core Tcl, representing a matrix as a list of lists:
|