I have a numpy array of strings of numbers that I am trying to convert to floats, but some of the numbers have stars around them. Is there any way to remove this without changing the actual number or its position (index) in the numpy arrray? Code below:
nums = np.array(['57', '98.8', '*32.56*', '4.36', '*654.56*', '89.21'])
Ideal output would be:
nums = np.array(['57', '98.8', '32.56', '4.36', '654.56', '89.21'])
After which I would be able to convert it into an array of floats instead of an array of strings