Answers for "mu python replicate array n times"

0

mu python replicate array n times

# Just use tile method which multiplies the array with given shape 
# and reshape method to structure it. 

x=np.tile(x,(3,1))
y=x.reshape(x.shape[0]*x.shape[1])
Posted by: Guest on January-17-2022

Python Answers by Framework

Browse Popular Code Answers by Language