Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Unable to parse string "ACTL6AS5" at position 0

This is another error I am getting:-
Unable to parse string "ACTL6AS5" at position 0

What is meant by this error?

ValueError                                Traceback (most recent call last)
pandas\_libs\lib.pyx in pandas._libs.lib.maybe_convert_numeric()

ValueError: **Unable to parse string "ACTL6AS5"**

During handling of the above exception, another exception occurred:

ValueError                                Traceback (most recent call last)
<ipython-input-51-c08b0b717a59> in <module>
----> 1 Combined_data_df["features"] = Combined_data_df ["features"].apply(pd.to_numeric)

I have attempted to fix it like this:- 

#Trying to fix error 'unable to parse string 'ACTL6A_S5' at position 0
print (Combined_data_df[pd.to_numeric(Combined_data_df.features, errors='coerce').isnull()])

Is this the right fix?

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

Thank you!

>Solution :

You can’t convert a string with letters to numeric, but yes you can coerce them to be NaN.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading