This package conducts the canonical correlation analysis for the longitudinal datasets.
You can install the released version of sparsemediation from CRAN with:
install.packages("lcca")
And the development version from GitHub with:
# install.packages("devtools")
devtools::install_github("seonjoo/lcca")
lcca(x,y)