An extension of the Whittaker–Henderson method of graduation