Rank-revealing QR

Anyone know how one might use the provided QR factorization and create a rank revealing QR factorization?