The new shingles vaccine is expensive, but worth it, according to a new analysis in JAMA Internal Medicine.

Shingles is a painful and sometimes debilitating nerve inflammation and blistering skin rash caused by the same virus that causes chickenpox. Anyone who has had chickenpox is susceptible to it many years later.

The old vaccine, Zostavax, is about 50 percent effective. The new one, Shingrix, provides 90 percent protection. It is given in two shots at $140 each, and it is recommended for people 50 and older. It will probably soon be covered by Medicare Part D and other insurers.

Using data from randomized trials, researchers calculated that using the new vaccine would save money over the long term, based on statistical measures that quantify the cost effectiveness of health care measures.