Research Article

Weather Forecasting Using Sliding Window Algorithm

Algorithm 1

Step  1. Take matrix ‘‘CD’’ of last seven days for current year’s data of size .
Step  2. Take matrix ‘‘PD’’ of fourteen days for previous year’s data of size .
Step  3. Make 8 sliding windows of size each from the matrix ‘‘PD’’ as
Step  4. Compute the Euclidean distance of each sliding window with the matrix ‘‘CD’’ as
Step  5. Select matrix as
    = Correponding_Matrix (Min. )
   
Step  6. For = 1 to
           (i) For compute the variation vector for the matrix ‘‘CD" of size as ‘‘VC’’.
           (ii) For compute the variation vector for the matrix ‘‘PD’’ of size as ‘‘VP’’.
           (iii) Mean1 = Mean (VC)
           (iv) Mean2 = Mean (VP)
           (v) Predicted Variation ‘‘ ’’
           (vi) Add ‘‘ ’’ to the previous day’s weather condition in consideration to get the predicted condition.
 Step  7.  End