

- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to Transpose a matrix in Single line in Python?
The NumPy package contains a very handy function transpose() to convert ndarray object into a transposed array
>>> a = np.array([[1, 2], [3, 4]]) >>> a array([[1, 2], [3, 4]]) >>> a.transpose() array([[1, 3], [2, 4]])
- Related Questions & Answers
- Transpose a matrix in Python?
- How to Transpose a Matrix using Python?
- Transpose a matrix in C#
- Transpose a matrix in Java
- Java program to transpose a matrix.
- Find the transpose of a matrix in Python Program
- Python Program to find the transpose of a matrix
- Compute a matrix transpose with Einstein summation convention in Python
- Program to find the transpose of given matrix in Python
- C++ Program to Find Transpose of a Matrix
- Java Program to Find Transpose of a Matrix
- How to calculate transpose of a matrix using C program?
- How to write a single line in text file using Python?
- How to provide multiple statements on a single line in Python?
- Java program to print the transpose of a matrix
Advertisements