  Jet shapes have the potential to play a role in many LHC analyses, for
example in quark-gluon discrimination or jet substructure analyses for hadronic
decays of boosted heavy objects. Most shapes, however, are significantly
affected by pileup. We introduce a general method to correct for pileup effects
in shapes, which acts event-by-event and jet-by-jet, and accounts also for
hadron masses. It involves a numerical determination, for each jet, of a given
shape's susceptibility to pileup. Together with existing techniques for
determining the level of pileup, this then enables an extrapolation to zero
pileup. The method can be used for a wide range of jet shapes and we show its
successful application in the context of quark/gluon discrimination and
top-tagging.
