merge historical to prediction df function