A Pattern Discovery Approach to Multivariate Time Series Forecasting