This simple extension treats the text of the active text editor document as a matrix (where elements are separated by whitespace) and offers some simple matrix operations.
To apply an operation, open the command palette in vscode (
Be aware that the text in the currently active editor window (representing a matrix), is replaced with the result of the matrix operation.
The text must represent a rectangular matrix with the exact same amout of elements on each line, separated by whitespace. A simple, valid matrix e.g. is:
The resulting matrix of the operation is always printed out with one space between every element.
The available commands in vscode are:
Transposes the rows and columns of the text:
Flip the characters on every line of the text
Flips the elements on each row (x axis):
Flip the lines of the text
Flips the lines of the text:
Rotate text by 90 degrees
Rotates the matix by 90 degrees:
Rotate text by 180 degrees
Rotates the matix by 180 degrees:
Rotate text by 270 degrees
Rotates the matix by 270 degrees: