I need to convert one into 1, two into 2 and so on.
one
1
two
2
Is there a way to do this with a library or a class or anythi
This code works for a series data:
import pandas as pd mylist = pd.Series(['one','two','three']) mylist1 = [] for x in range(len(mylist)): mylist1.append(w2n.word_to_num(mylist[x])) print(mylist1)