Error in plotting Prediction Intervals in R

Please check out the policy on cross-posting.