Tutorials
Courses
Go Premium
Data Structure
Java
Python
HTML
Interview Preparation
DSA
Practice Problems
C
C++
Java
Python
JavaScript
Data Science
Machine Learning
Courses
Linux
DevOps
SQL
Web Development
System Design
Aptitude
GfG Premium
Similar Topics
Web Technologies
32.1K+ articles
Python
19.6K+ articles
Misc
7.8K+ articles
Machine Learning
2.5K+ articles
AI-ML-DS With Python
2.0K+ articles
Python-numpy
1.3K+ articles
python
1.2K+ articles
Numpy
73+ articles
Python numpy-program
33+ articles
Python numpy-matlib
2+ articles
Python numpy-arrayManipulation
200+ posts
Recent Articles
Popular Articles
NumPy| How to get the unique elements of an Array
Last Updated: 15 July 2025
To find unique elements of an array we use the numpy.unique() method of the NumPy library in Python.It returns unique elements in a new sorted array.Example:Python3 ...
read more
Python
Python-numpy
Python numpy-program
Python numpy-arrayManipulation
NumPy | Get the Powers of Array Values Element-Wise
Last Updated: 15 July 2025
To calculate the power of elements in an array we use the numpy.power() method of NumPy library.It raises the values of the first array to the powers in the second array.E...
read more
Python
Python-numpy
Python numpy-program
Python numpy-arrayManipulation
How to find the maximum and minimum value in NumPy 1d-array?
Last Updated: 15 July 2025
Let's see the various ways to find the maximum and minimum value in NumPy 1d-array.Method 1: Using numpy.amax() and numpy.amin() functions of NumPy library.numpy.amax(): T...
read more
Python
Python-numpy
Python numpy-program
Python numpy-arrayManipulation
Calculate the sum of all columns in a 2D NumPy array
Last Updated: 21 July 2021
Let us see how to calculate the sum of all the columns in a 2D NumPy array.Method 1 : Using a nested loop to access the array elements column-wise and then storing their s...
read more
Python
Python-numpy
Python numpy-arrayManipulation
Python numpy-Mathematical Function
Create a contiguous flattened NumPy array
Last Updated: 15 July 2025
Let us see how to create a contiguous array in NumPy.The contiguous flattened array is a two-dimensional and multi-dimensional array that is stored as a one-dimensional ar...
read more
Python
Python-numpy
Python numpy-arrayManipulation
How to make a NumPy array read-only?
Last Updated: 04 November 2022
Let's discuss how to make NumPy array immutable i.e that can not be rewritten or can't be changed. This can be done by setting a writable flag of the NumPy array to false....
read more
Python
Python-numpy
Python numpy-arrayManipulation
How to get all 2D diagonals of a 3D NumPy array?
Last Updated: 15 July 2025
Let's see the program for getting all 2D diagonals of a 3D NumPy array. So, for this we are using numpy.diagonal() function of NumPy library. This function return specifie...
read more
Python
Picked
Python-numpy
Python numpy-arrayManipulation
Insert a new axis within a NumPy array
Last Updated: 15 July 2025
This post deals with the ways to increase the dimension of an array in NumPy. NumPy provides us with two different built-in functions to increase the dimension of an array...
read more
Python
Python-numpy
Python numpy-arrayManipulation
Find the most frequent value in a NumPy array
Last Updated: 15 July 2025
In this article, let's discuss how to find the most frequent value in the NumPy array. Steps to find the most frequency value in a NumPy array:Create a NumPy array.Apply b...
read more
Python
Python-numpy
Python numpy-arrayManipulation
Flatten a Matrix in Python using NumPy
Last Updated: 15 July 2025
Let's discuss how to flatten a Matrix using NumPy in Python. By using ndarray.flatten() function we can flatten a matrix to one dimension in python.Syntax:numpy_array.flat...
read more
Python
Python-numpy
Python numpy-arrayManipulation
Extracting the real and imaginary parts of an NumPy array of complex numbers
Last Updated: 15 July 2025
Numpy library gives us functions such as real() and imag() to find real and imaginary parts of a complex number. real() : To find real part of the complex number ima...
read more
Python
Python-numpy
Python numpy-arrayManipulation
How to convert 1-D arrays as columns into a 2-D array in Python?
Last Updated: 15 July 2025
Let's see a program to convert 1-D arrays as columns into a 2-D array using NumPy library in Python. So, for solving this we are using numpy.column_stack() function of Num...
read more
Python
Python-numpy
Python numpy-arrayManipulation
Find unique rows in a NumPy array
Last Updated: 15 July 2025
Finding unique rows means removing duplicate rows from a 2D array so that each row appears only once. For example, given [[1, 2], [3, 4], [1, 2], [5, 6]], the unique rows ...
read more
Python
Python-numpy
Python numpy-arrayManipulation
How to Concatenate two 2-dimensional NumPy Arrays?
Last Updated: 15 July 2025
Sometimes it might be useful or required to concatenate or merge two or more of these NumPy arrays. In this article, we will discuss various methods of concatenating two 2...
read more
Python
Python-numpy
Python numpy-arrayManipulation
Using NumPy to Convert Array Elements to Float Type
Last Updated: 15 July 2025
Converting array elements to float type in Python means transforming each item in an array into a floating-point number. For example, an array like ["1.1", "2.2", "3.3"] c...
read more
Python
Picked
Python-numpy
Python numpy-arrayManipulation
1
2
3
4
...
14
We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our
Cookie Policy
&
Privacy Policy
Got It !