Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

python tableau 2d

>>> u = np.arange(1, 16)
>>> u
array([ 1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12, 13, 14, 15])
>>> np.shape(u)
(15,)
>>> u.shape = (3, 5)
>>> u
array([[ 1,  2,  3,  4,  5],
       [ 6,  7,  8,  9, 10],
       [11, 12, 13, 14, 15]])
>>> np.shape(u)
(3, 5)
Source by courspython.com #
 
PREVIOUS NEXT
Tagged: #python #tableau
ADD COMMENT
Topic
Name
8+7 =