string search replace

Hi all,

can any one help me out to change my data below :

my sample data is like this :

x.txt

'128' '229' 'LOW ' '' '' '179,KG' 'RAB' '' 'PA' '27600' 'M' '6-389' '' 'M' 'ABC' 'M' 'XYZ' '123'
--

I would like to change 'M' of the with 'Male'
(I think I have to search 27th occurence of ' and M)

can anyone send me command?

Thanks
Krishna

If you want to replace every occurence of 'M' with 'Male' just pipe your output to:

sed 's/\'M\'/Male\'/g