astype in NumPy Python | Module NumPy Tutorial - Part 05

Publié le: 21 septembre 2022
sur la chaîne: Koolac
3,646
55

In this video, we will talk about astype function in numpy module python with example. Maybe you ask: How do I convert a NumPy array to integer? or float or ....? And the answer to all of these questions is: using the astype function.

==================================
NumPy Module Tutorial Playlist for Machine Learning:
==================================
   • Numpy Python Playlist  

==================================
Source Code:
==================================
import numpy as np
x=np.array(["1","2","3"])
y=x.astype(float)
print(y)
print(y.dtype)


Sur cette page du site, vous pouvez voir la vidéo en ligne astype in NumPy Python | Module NumPy Tutorial - Part 05 durée online en bonne qualité , qui a été Téléchargé par l'utilisateur Koolac 21 septembre 2022, Partagez le lien avec vos amis et connaissances, sur youtube cette vidéo a déjà été regardée 3,646 fois et il a aimé 55 téléspectateurs. Bon visionnage!