update mkpr function