I have multiple CSV files that could represent similar things in multiple ways. For instance, 15 years can be written either as age: 15, age (years): 15, age: 15 years (these are all the patterns I've seen till now). I'd like to replace all those with 15 years. I know how to do it when I know the actual age or the column number, but the age is definitely different for each occurrence and the column is not fixed. The csv files could be like below:
CSV1:
h1,h2,h3
A1,age:15,hh
B3,age:10,fg
Desired CSV1
h1,h2,h3
A1,15 years,hh
B3,10 years,fg
When ever its just age: 15, its definitely years and not months or any other unit.
str.translaemethod if so. Create a table that maps letters to empty strings. An example is here