refer to code:
.
import numpy as np
import pandas as pd
# Create a numpy ndarray
array = np.random.rand(5, 3)
print('array: \n', array)
# Convert the numpy ndarray to a pandas DataFrame
df = pd.DataFrame(array, columns=['Column1', 'Column2', 'Column3'])
# Print the DataFrame
print('df: \n',df)
..
Thank you.
www.marearts.com
ππ»♂️
No comments:
Post a Comment