Python | numpy.array_split() method Last Updated : 17 Sep, 2019 Summarize Comments Improve Suggest changes Share Like Article Like Report With the help of numpy.array_split() method, we can get the splitted array of having different dimensions by using numpy.array_split() method. Syntax : numpy.array_split() Return : Return the splitted array of one dimension. Example #1 : In this example we can see that by using numpy.array_split() method, we are able to split the array in the number of subarrays by passing it as a parameter. Python3 1=1 # import numpy import numpy as np array = np.arange(9) # using numpy.array_split() method gfg = np.array_split(array, 4) print(gfg) Output : [array([0, 1, 2]), array([3, 4]), array([5, 6]), array([7, 8])] Example #2 : Python3 1=1 # import numpy import numpy as np array = [[1, 2, 3], [4, 5, 6], [7, 8, 9]] # using numpy.array_split() method gfg = np.array_split(array, 3) print(gfg) Output : [array([[1, 2, 3]]), array([[4, 5, 6]]), array([[7, 8, 9]])] Comment More infoAdvertise with us Next Article numpy.array_repr() in Python J jitender_1998 Follow Improve Article Tags : Python Python-numpy Python numpy-arrayManipulation Practice Tags : python Similar Reads numpy.array_str() in Python numpy.array_str()function is used to represent the data of an array as a string. The data in the array is returned as a single string. This function is similar to array_repr, the difference being that array_repr also returns information on the kind of array and its data type. Syntax : numpy.array_st 2 min read numpy.array_repr() in Python numpy.array_repr()function is used to convert an array to a string. Syntax : numpy.array_repr(arr, max_line_width=None, precision=None, suppress_small=None) Parameters : arr : [array_like] Input array. max_line_width : [int, optional] The maximum number of columns the string should span. Newline cha 2 min read NumPy Array in Python NumPy (Numerical Python) is a powerful library for numerical computations in Python. It is commonly referred to multidimensional container that holds the same data type. It is the core data structure of the NumPy library and is optimized for numerical and scientific computation in Python. Table of C 2 min read Python | Numpy numpy.ndarray.__sub__() With the help of Numpy numpy.ndarray.__sub__(), We can subtract a particular value that is provided as a parameter in the ndarray.__sub__() method. Value will be subtracted to each and every element in a numpy array. Syntax: ndarray.__sub__($self, value, /) Return: self-value Example #1 : In this ex 1 min read numpy.vsplit() function | Python numpy.vsplit() function split an array into multiple sub-arrays vertically (row-wise). vsplit is equivalent to split with axis=0 (default), the array is always split along the first axis regardless of the array dimension. Syntax : numpy.vsplit(arr, indices_or_sections) Parameters : arr : [ndarray] A 2 min read Python | Numpy.dsplit() method With the help of Numpy.dsplit()() method, we can get the splitted dimensions of an array by using Numpy.dsplit()() method. Syntax : Numpy.dsplit(numpy.array(), split_size) Return : Return the array having splitted dimensions. Example #1 : In this example we can see that using Numpy.expand_dims() met 1 min read Like