SpatialKDE is an R package available from both GitHub and CRAN. The package is a reimplementation of Heatmap tool from QGIS to R. The main reason for the reimplementation were various shortcomings of existing tools for KDE in existing packages. These shortcomings were especially significant when considering spatial data and analyses.
The instalation from GitHub requires RTools or other C++ compiler.
remotes::install_github("JanCaha/SpatialKDE")
Without C++ compiler you can download a compiled release for Windows or install directly from CRAN.
install.packages("SpatialKDE")