9951 explained code solutions for 126 technologies


python-numpyHow to save Numpy array to CSV


import numpy as np
a = np.array([1, 2, 3, 4, 5])
np.savetxt('/tmp/numpy.csv', a)ctrl + c
import numpy as np

load Numpy module for Python

np.array

declare Numpy array

.savetxt(

save given Numpy array into CSV file