Sed is often used to replace words in input, but did you know that you can replace a set of characters with another set of corresponding characters? This is accomplished by use of the ‘y’ command. It’s essentially the same as the ‘tr’ utility and works as follows:
sed 'y/<input_chars>/<replace_chars>/' input_file.txt
An example of replacing all uppercase vowels with lowercase vowels:
sed 'y/AEIOU/aeiou/' input_file.txt
The length of each set of characters must match or the command will result in an error.