Markov Chain: First Step Towards Heat Wave Analysis in Malaysia
Total Page:16
File Type:pdf, Size:1020Kb
Mathematics and Statistics 8(2A): 28-35, 2020 http://www.hrpub.org DOI: 10.13189/ms.2020.081305 Markov Chain: First Step towards Heat Wave Analysis in Malaysia Nur Hanim Mohd Salleh1,*, Husna Hasan1, Fariza Yunus2 1School of Mathematical Sciences, Universiti Sains Malaysia, Malaysia 2Malaysian Meteorological Department (Jabatan Meteorologi Malaysia), Malaysia Received August 8, 2019; Revised October 8, 2019; Accepted February 20, 2020 Copyright©2020 by authors, all rights reserved. Authors agree that this article remains permanently open access under the terms of the Creative Commons Attribution License 4.0 International License Abstract Extreme temperature has been carried out located in the western region of Peninsular Malaysia around the world to provide awareness and proper including Perlis, Kedah, Perak, Kuala Lumpur and Johor opportunity for the societies to prepare necessary [1]. The level 1 alert was issued as the daily maximum arrangements. In this present paper, the first order Markov temperature exceeding 35˚C for three consecutive days. chain model was applied to estimate the probability of extreme temperature based on the heat wave scales provided by the Malaysian Meteorological Department. In 2. Background of Study this study, the 24-year period (1994-2017) daily maximum Stochastic processes are progressively being used for temperature data for 17 meteorological stations in Malaysia modeling and predicting climate data. The arising need of was assigned to the four heat wave scales which are using this approach in climate and weather models is monitoring, alert level, heat wave and emergency. The caused by the inability to resolve all necessary processes analysis result indicated that most of the stations had three and scales in comprehensive numerical weather and categories of heat wave scales. Only Chuping station had climate prediction models [2]. One of the famous stochastic four categories while Bayan Lepas, Kuala Terengganu, models applied to evaluate climate data is Markov chain. Kota Bharu and Kota Kinabalu stations had two categories. The Markov chain model is a commonly used tool for The limiting probabilities obtained at each station showed simulating time series of discrete random variables [3]. a similar trend which the highest proportion of daily This model is considered as a memoryless process due to maximum temperature occurred in the scale of monitoring the probability of transitioning from one state to another and followed by the alert level. This trend is apparent when depends only on the current state and not on the past. The the daily maximum temperature data revealed that detailed theory and structure of Markov chain can be Malaysia is experiencing two consecutive days of referred to in some textbooks stochastic processes [4, 5]. temperature below 35˚C. Many researchers around the world have applied Markov Keywords Markov Chain, Maximum Temperature, chain model to analyze the climate data. In Malaysia, Heat Wave, Transition Probability Matrix, Limiting several similar analyses also have been attempted by the Probabilities researchers to model the daily observation of rainfall [6], wind speed [7] and maximum temperature [8]. In the year 2015, Hasan [8] proposes the application of Markov chain onto daily maximum temperature data. The study covers only the northern region of Peninsula Malaysia. A scale for 1. Introduction the state of transition was determined by using the physiological equivalent temperature (PET). The same One of the most important climate parameters which scale was applied by Hassan and Hasan [9] in the year 2017 affect natural and social phenomena is the temperature. The to determine the steady-state probability for the daily temperature that has exceeded the average temperature for maximum temperature across Peninsular Malaysia. This a given area is considered as a heat wave. Recently, on study is the extension of these two works. The main February 2019, the Malaysian Meteorological Department purpose of the current work is to describe the heat wave (MMD) issued a level 1 alert for ten areas in the country condition in Malaysia by applying Markov chain model amidst the ongoing nationwide heat wave. The ten areas are onto the daily maximum temperature data. Mathematics and Statistics 8(2A): 28-35, 2020 29 Figure 1. Location of 17 selected stations in Malaysia 3. Data Characteristics 4.2. A Markov Chain Model for Daily Maximum Temperature The data used in this study are daily maximum temperature measured in degree Celsius (˚C) from 17 There are two properties need to be distinguished when meteorological stations across Malaysia. These data are applying Markov chain model to the climate data. The first provided by Malaysian Meteorological Department (MMD) property is the “state”, defined as the number of different with less than 2% missing data. Each station has at least 24 values that the variable can have and the second property is the “order”, described as the number of previous values years of daily data except KLIA station (19 years). The used to determine the state-to-state transition probabilities location of each station is illustrated in Figure 1. Fourteen [3]. In this study, the Markov chain model applied on the stations are located in the west part of Malaysia (Peninsular daily maximum temperature is the first order model with Malaysia) while remaining three stations are located in the four states which can be described as follows. Let X be eastern region of Malaysia (Sabah and Sarawak). t defined as the state of temperature at t th day where Xit = , i =1,2,3,4 4. Methodology 1. if day t is at state of monitoring, 2. if day is at state of alert level, 3. if day is at state of heat wave, 4.1. Heat Wave Scales 4. if day is at state of emergency. The daily maximum temperature model based on a Assuming that the state of temperature is dependent on Markov chain describes the temperature changes by the condition of the previous day, then X t follows the following the heat wave scales. Four levels of heat wave first-order Markov chain. As an example, the below scale provided by the Malaysian Meteorological equations express the conditional probabilities of the Department are used in this study. The daily temperature temperature at state j on day t depending on the data in this study is assigned to its heat wave scales. The temperature at state i on day t −1 . The transition descriptive terms for each scale together with the range of probabilities estimated from the historic measurements, daily maximum temperature are listed in Table 1. signify the probabilities of temperature from state i to Table 1. The details of heat wave scales state j . In general, the transition probability from state into state can be written as Descriptive Range of daily maximum temperature Scale term (˚C) pij= P[ X t = j | X t−1 = i ] , ij,= 1,2,3,4 1 Monitoring below 35 2 Alert level [35,37] 4.3. Development of Transition Probability Matrix 3 Heat wave (37, 40] To obtain the transition probability matrix P , the data 4 Emergency above 40 with the previous state and current state j are first counted. Then, the counted values, m will be sorted and ij placed into a transition count matrix M . Since there are 30 Markov Chain: First Step towards Heat Wave Analysis in Malaysia four states of transition used in this study, the transition of packages and other packages that can be downloaded and daily maximum temperature can be divided into the 16 installed. These packages contain R functions, data and cases which can constitute the following count matrix . compiled code in a well-defined format. In this study, the Define package named ‘markovchain’ has been used to manage discrete time Markov chain more easily. It was developed m11 m 12 m 13 m 14 and maintained by Giorgio Alfredo Spedicato and m m m m M=21 22 23 24 published on 21st January 2019. m m m m 31 32 33 34 An individual transition count matrix for each station can m41 m 42 m 43 m 44 be created using a createsequenceMatrix function while the transition probability matrices can be computed using which is then transformed into the transition probability markovchainFit function. Using a plot function, a better matrix, , that is understanding of the Markov Chain model can be gained p11 p 12 p 13 p 14 through a transition diagram. This transition diagram is a graphical representation of a Markov chain which is p21 p 22 p 23 p 24 P= equivalent to its transition probability matrix [10]. p p p p 31 32 33 34 Furthermore, a steady-state distribution or a limiting state p p p p 41 42 43 44 probability can also be computed using steadyStates m 4 function. P = ij where ij and Pij =1 mij j=1 j 5. Result and Discussion 4.4. Development of Limiting State Probabilities 5.1. Descriptive Statistics The n-step transition probabilities can be defined as The descriptive statistics consisting of mean, maximum follows: and minimum values (˚C) of the daily maximum n temperature from the selected metrological stations are p11 p 12 p 13 p 14 p p p p presented in Table 2. The mean values of the observed data P=n 21 22 23 24 range from 31.30˚C to 32.94˚C. The highest value of p p p p 31 32 33 34 maximum temperature is recorded at Chuping (40.10˚C) p p p p 41 42 43 44 followed by Alor Setar (39.10˚C) station. It is interesting to As n increases, the n-step transition probabilities note that both stations are located in the northern region of converge to certain probabilities: Peninsular Malaysia.