There are so many packages that provide this calculation although most of them are based on points and not data frames or maybe I am making a mistake! I have found this meth