As part of broader program I am working on, I ended up with object arrays with strings, 3D coordinates and etc all mixed. I know object arrays might not be very favorite in
This problem usually happens when you have a dataset with different types, usually, dates in the first column or so.
What I use to do, is to store the date column in a different variable; and take the rest of the "X matrix of features" into X. So I have dates and X, for instance.
Then I apply the conversion to the X matrix as:
X = np.array(list(X[:,:]), dtype=np.float)
Hope to help!