I looked in the Pandas library method (.replace), and I am trying to parse all the special characters in a pandas data frame. Meaning for a special character = '½', I am pulling the data as this:
import pandas as pd url = 'http://feeds.donbest.com/ScoresWebApplication/servicePage.jsp? type=SCHED&leagueId=0&schedDate=20081217&subscr=1' data = pd.read_html(url) I need to preserve the number and just replace this '½' with a 0.5 when trying this piece of code gets me this:
data[1].replace(regex=True,inplace=True,to_replace='½',value=0.5) It replaces the full data from 172½ for 0.5 instead of preserving its number like this 172.5.
apply, identify when it matches, when it does: find the integer part and add it to 0.5.