You can use lapply as follows:
lapply(predict(pp)$fcst[LOC],'[',,1)
For instance:
data(Canada) fit <- VAR(Canada, p = 2, type = "none") LOC <- c('e','U') lapply(predict(fit)$fcst[LOC],'[',,'fcst') lapply(predict(fit)$fcst[LOC],'[',,1) $e [1] 962.3490 962.7852 963.1305 963.4016 963.6116 963.7742 963.9023 964.0081 964.1026 964.1954 $U [1] 6.764097 6.751969 6.804301 6.900299 7.030548 7.184748 7.353441 7.528150 7.701521 7.867432
source share