researchdatapod.com
How to Solve Python AttributeError: ‘list’ object has no attribute ‘astype’
This error occurs when you try to call the astype() method on a list as if it were a NumPy ndarray. You can solve this error by converting the list to an array using the numpy.array() method then c…