maxRank method