I need to replace a stiff twist-grip shifter with a thumb shifter to make gear down-changes easier for my wife. There is a choice of two available locally: Shimano SL-TX50R Tourney and Shimano Altus SLM310R7AT. Are these compatible with a Shimano TX rear derailleur?
If you have a 7 speed rear cassette, any Shimano 7 speed shifter should work.
Shimano's Altus range sits just above the Tourney TX range, so an Altus shifter would nominally be a little better, but matching a TX shifter with a TX derailleur would be fine.
it does not matter. today the Shimano components are mostly compatible with each other. And for a 7-speed derailleur, both of your choices will do the job.
If money doesn't matter, take the higher ranked component, in this case, the Altus shifter.