Proceedings of he 00 Inernaional Conference on Indusrial Engineering and Operaions Managemen Dhaka, Bangladesh, January 9 0, 00 Inermien Demand orecas and Invenory Reducion Using Bayesian ARIMA Approach Mohammad Anwar Rahman Indusrial Engineering Technology The Universiy of Souhern Mississippi 730 Eas Beach Blvd, Long Beach, MS 39560, USA Bhaba R. Sarker Deparmen of Indusrial Engineering Louisiana Sae Universiy Baon Rouge, LA 70803, USA Absrac Naural calamiies (e.g., hurricane, excessive ice-fall) may ofen impede he invenory replenishmen during he peak sale season. Due o he exreme siuaions, sales may no occur and demand may no be recorded. This sudy focuses on forecasing of inermien seasonal demand by aking random demand wih a proporion of zero values in he peak sale season. Demand paern for a regular ime is idenified using he seasonal ARIMA (S-ARIMA) model. The sudy proposes a Bayesian procedure o he ARIMA (BS-ARIMA) model o forecas he peak season demand which uses a dummy variable o accoun for he pas years inermien demand. To capure uncerainy in he B-ARIMA model, he non-informaive prior disribuions are assumed for each parameer. Bayesian updaing is performed by Markov Chain Mone Carlo simulaion hrough he Gibbs sampler algorihm. A dynamic programming algorihm under periodic review invenory policy is applied o derive he invenory coss. The model is esed using parial demand of seasonal apparel produc in he US during 996-05, colleced from he US Census Bureau. Resuls showed ha, for inermien seasonal demand forecas, he BS-ARIMA model performs beer and minimizes invenory coss han do S-ARIMA and modified Hol-Winers exponenial smoohing mehod.. Inroducion The random occurrences of seasonal demand are sudied o manage he invenory a minimum coss. The invenory replenishmen and sales can be inerruped due o naural calamiies. Demand of such producs is ofen inermien which may conain a proporion of zero values. Tradiional forecasing mehods can be inappropriae for forecasing such seasonal demand ha increases during specific ime period in a year. These forecas obained by he auoregressive inegraed moving average (ARIMA) models are found o be beer compared o oher ways of modeling. The focus of his paper is o demonsrae he invenory cos reducions hrough he applicaion of an appropriae demand forecas of a seasonal produc. A ime series from January 996 o June 005 of a seasonal apparel demand in he U.S., colleced from he U.S. Census Bureau, is seleced. To exhibi he inermien feaures in he seleced ime series, six arbirarily chosen values during a peak season from July-December 004 are considered unavailable. A seasonal ARIMA (S-ARIMA) model has been consruced o forecas he peak season demand from July-December 005. Time series forecasing models are increasingly applied o forecas seasonal demand and shor-life producs Makridakis a. el. (998). Gardner and Diaz-Saiz (00) analyzed forecasing implemenaion problems in invenory conrol sysems (safey sock invesmen) for seasonal ime series. Under an auoregressive moving average (ARMA) assumpion, Kurawarwala and Masuo (998) esimaed he seasonal variaion of PC producs demand using demand hisory of pre-season producs. Miller and Williams (004) incorporaed seasonal facors in heir model o improve forecasing accuracy while seasonal facors are esimaed from muliplicaive model. Hyndman (004) exended Miller and Williams (004) work by applying various relaionships beween rend and seasonaliy under seasonal ARIMA procedure. The classical ARIMA approach becomes prohibiive, and in many cases i is impossible o deermine a model, when seasonal adjusmen order is high or seasonal adjusmen diagnosics fails o indicae ha ime series is sufficienly saionary afer seasonal adjusmen. In such siuaions,
he saic parameers of he classical ARIMA model are considered he main resricion o forecasing high variable seasonal demand. Anoher resricion of he classical ARIMA approach is ha i requires a large number of observaions o deermine he bes fi model for a daa series. In he ARIMA model, if he Bayesian approaches are used, he resricion of he saic values of he parameers is relieved by imposing he probabiliy disribuions o represen he parameers. Alhough he pracices of Bayesian ARIMA models for seasonal forecas are more realisic, bu he lieraure on Bayesian mehods applied o seasonal ARIMA ime series is limied. In his sudy, afer he classical ARIMA model is developed for he seleced daase, and he Bayesian mehod is applied o he S-ARIMA model. A Bayesian approach o he S-ARIMA model is sudied wih he special relevan o he problem ha forecas should be performed from an incomplee ime series. An adapive approaches of Hol-Winers (H-W) exponenial smoohing echnique is also sudied o forecas he ime series. A periodic review invenory model has been sudied depending on he forecas obained by he above models. The opimal invenory coss have been derived for each forecas via dynamic programming. The bes forecas is considered as he one which provides he minimum invenory coss.. S-ARIMA Model Idenificaion In his paper, he S-ARIMA process begins by ransforming he original ime series ino a saionary series by aking he mean difference of daa. The saionariy of he ime series has been achieved afer he firs and seasonal (d, ) difference of order. The auocorrelaion funcion (AC) and parial AC (PAC) have been idenified as decreasing, sinusoidal and alernae in sign and showed ha he order of p and q for boh AR(p) and MA(q) componens for seasonal and non-seasonal series can a he mos be one. Using goodness-of-fi saisics, e.g., (i) Akaike informaion crierion (AIC), (ii) Schwarz Bayesian informaion crierion (BIC) and he chi-square ( χ ) es, he bes srucure of S-ARIMA (p, d, q) (P, D, Q) has been idenified as S-ARIMA (0,,)(,,0). The esimaed parameers of he S-ARIMA are repored in Table. Table : Esimaed values of he S-ARIMA parameers Sandard Parameer Esimae -value Pr> lag error MU 6.80 7889.0 0.6 0.8700 0 MA, 0.74 0.07 0.59 0.000 AR, -0.35 0.09-3.59 0.0003 Boh he moving average "MA," and he auoregressive AR, parameers are 0.735 and -0.35, respecively wih significan values. The parameers are esimaed using he maximum likelihood mehod by SAS sofware. 3. Poin orecas wih S-ARIMA Model The S-ARIMA model (0,,) (,,0) has been idenified bes model for he ime series and enailed o forecas he peak demand. In he S-ARIMA model, he auoregressive erm p = 0, P = (seasonal) [ha is, ( 0)( φ B ) ]; differencing erm d =, D = (seasonal difference) [ha is, ( B)( B ) ] and moving average erm is q =, Q = 0 (seasonal) [ ( θ B)( 0) ]. The model has (, ) period differencing, he auoregressive facors is ( φb ) = ( + 0.35096 B ), he moving average facors is ( θb) = ( - 0.7357 B), and he esimaed mean, C = 6.8. Transforming auoregressive erms and coefficien, he model is given by C + ( θb) e y =. () ( φb ) ( B) ( B ) Afer expanding, and ransforming he back operaor, Equaion () can be simplified in he following form, y = y + ( + φ ) y ( + φ) y 3 φy 4 + φy 5 + e θe + C. () In order o forecas one period ahead, ha is, y +, he subscrip of is increased by one uni, hroughou, and using Using φ = -0.35 and θ = 0.735, he Equaion () is given by
y + = y + 0.65y 0.65y + 0.35y 3 0.35y 4 + e+ 0.735e + 6.8 (3) In order o forecas for he period 5 (i.e., July 005), Equaion (3) is given by y 0.65 0.65 0.35 0.35 ˆ 0.735 ˆ 5 = y4 + y03 y0 + y9 y90 + e5 e4 + 6.8 The forecas resuls for sage- a 005 using S-ARIMA is shown in Table 4. 4. Bayesian Sampling-based ARIMA Model (BS-ARIMA) Bayesian mehods have been widely applied in ime series conex. The Markov Chain Mone Carlo (MCMC) mehod is efficien and flexible algorihms for conducing poserior inference of Bayesian model hrough simulaion. Depending on he ime series daa, a Markov chain can be consruced in various ways and he Gibbs sampler, a commonly used algorihm applied here o derive he poserior parameers of he forecasing model. The key advanage of developing S-ARIMA model from Bayesian perspecives is he capaciy o forecas demand from an incomplee ime series which conains boh zero and non-zero daa. In his model, he form of S-ARIMA (0,,)(0,,) model in Equaion (3) has been applied. The model can be expressed in he following, y = y + φ y + φ y 3 φ3 y 4 y 5 + e θe + C where φ = ( + φ), φ = ( + φ), and φ 3 = φ 4 = φ. I is noed ha he demand for he sage- period from July- December 004 are no available. A dummy variable w is added o Equaion (7) o accoun he missing values of he daa series. The form of he BS-ARIMA afer adding dummy variable is given by y = y + φ y + φ y 3 φ3 y 4 y 5 + e θe + C + w. (4) The dummy variable w, 0 w is added o represen he saus of pas informaion, e.g., if he dummy variable is se o zero when demand informaion of a period is known. A scaled value of w may be se (from 0 o ) o reflec he parial demand of a period. The value of w as.0 when demand informaion for a period is missing, while he value 0.50 indicaes incomplee demand informaion, i.e., approximaely 50% demand was observed. or dummy variable w, he values placed a July o December 004 are shown in Table. Table : Values of dummy variables for July o December, 004 (unis in million) Demand Jul Aug Sep Oc Nov Dec Projeced, y p.54 3.8 4.4 4.05.4.75 Sage-, y s-.55.55.55.55.55.55 Dummy variable, w 0.39 0.59 0.63 0.6 0.36 0. or he daa series y, ( =,,, n, n+, N), he y corresponds o he demand of a period, where a vecor ime series from n+ o N, { y = ( N n) } is he predicion periods. A Bayesian compuaion is carried ou o predic he demand for (N-n) period hrough he use of sampling-based algorihm. The paricular sampling-based approach used in his model is a Markov chain Mone Carlo mehod based on he Gibbs sampler algorihm. The likelihood funcion for n observaion y, (y, y,, y n ) is denoed by f ( y; ψ ), where ψ = ( φi, θ, β, τ ) wih φ i = ( φ,..., φ4 ). The condiional likelihood obained from he facorizaion heorem (Zellner, 996) is given by f ( y Ψ ) = f ( y Ψ ) f ( y y, Ψ )... f ( yn y,..., yn, Ψ ). Given he prior disribuion for Ψ, f ( Ψ y ), he poserior densiy for Ψ is given by f ( Ψ y ) f ( y Ψ ). f ( Ψ ). If y = ( yn+,..., y N ), for predicing (N - n) = L period, he predicive densiy is given by f ( y y ) = ( y y, Ψ ). f ( Ψ ) dψ, (5) where ( y y, Ψ ) is he densiy of he fuure daa y. The L seps ahead forecas is hen f ( y y, Ψ ) = ( yn+ y, Ψ ) ( yn+ yn+, y, Ψ )... ( yn+ L yn+, yn+ L, y, Ψ ) dψ. To obain a sample of predicions from he densiy funcion in Equaion (9), for each Ψ, one needs o draw from ( y y, Ψ ). ollowing are he seps o predic he fuure values of he BS-ARIMA model, Sep : Daa Definiions 3
y, {for in (: n) } w, {Dummy (), for in : N} Sep : Model Descripion y ~ Normal(, τ ) {for in (: n)}, where µ µ + = C + φ y + φ y 3 + φ3 y 4 y 5 + e + θe βw, and Sep 3: Assigning Priors µ ~ Normal (0, 0.00), i β ~ Normal(0, 0.00 ), τ ~ Chi-sq () Sep 4: orecass Period { = n + N} y Normal[, ] ( new) ~ µ ( new) τ φ ~ Normal(0, 0.00 ), µ + 4 τ = σ θ i ~ Normal(0, 0.00 ), ( new) = C + φ y + φ y 3 + φ3 y 4 y 5 + e + θe βw {for in (n +: N)} Carlin and Gelfand (990) illusraed ha he poin esimaes arising from ( y y, Ψ ) perform well if he variance of he predicive disribuion remain small. In Sep 3, he following non-informaive prior disribuion has been used for each parameer. The prior disribuions Normal(0, 0.00) are assumed for coefficien φ and θ. Parameer β is expeced o follow a relaively informaive prior disribuion as Normal(.0, 0.). The precision (a reciprocal of variance), τ follows a chi squared disribuion wih one degree of freedom. The choice of prior disribuion is followed by (Gelman e. al., 004; Congdon, 003). In he model, he esimaed parameers of Bayesian ARIMA model are shown in Table 3. Table 3: Esimaed parameers of Bayesian ARIMA model (unis in million) node mean S.dev.50% median 97.50% node mean S.dev.50% median 97.50% alpha 0.5 0.6-0.7 0.5 0.48 alpha4 0.03 0. -0.39 0.03 0.44 alpha 0.3 0.5-0.073 0.3 0.53 hea -0.0 0.67 -.45-0.008.38 alpha3 0.68 0.9 0.9 0.68.05 bea.00 3. -5.49.05 7.30 Acual demand, he simulaed resuls of he BS-ARIMA and S-ARIMA resuls for sage- period of 005 are shown in Table 4. The poserior models are derived using MCMC approach hrough Bayesian inference using Gibbs Sampling (BUGS) package Table 4: Demand orecas by BS-ARIMA model (unis in million) BS-ARIMA model S-ARIMA model Monh Acual demand Esimae Sd Sd.5% Med 97.5% Esimae error error.5% 97.5% Jul.83.47 0.7.07.46 3.88.74 0.38 0.38 3.50 Aug 3.33 3.6 0.73.9 3.6 5.07 3.65 0.40 0.40 4.34 Sep 4.0 4.77 0.74 3.3 4.76 6. 4.9 0.4 0.4 5.96 Oc 5.3 5.9 0.73 3.89 5.8 6.76 5.03 0.4 0.4 6.9 Nov 3.46 4.8 0.77.75 4.8 5.76.69 0.44 0.44 4.3 Dec.8.97 0.77.53.96 4.50.70 0.45 0.45 3.58 Adapive exponenial smoohing forecasing (Hol-Winer) echnique is widely spread in pracice, has been used o compare he proposed model. Muliplicaive exponenial smoohing (M-ES) model, defined as d + T = ( R + T G ) S + T L has been applied o compare he forecas for nex T periods, where is he esimae of level index, is he esimae of rend, and is he esimae of seasonal componen (seasonal index). The
iniial values of he parameers are deermined using he daa from July 00 o December 00 and he values are modified in subsequen years. The daa series from January 003 o June 005 are used o adjus he weigh of he smoohing parameers and demand forecas is performed for he sage- (July o December) in 005. 5. Invenory Cos Compare o Evaluae he Bes orecas In his secion, he cos saving approach in he invenory of he seasonal produc is presened. A monhly review plan is considered for periodic invenory replenishmen. There are ( =,,, n) forecasing periods a sage- and he demand forecas a any period is y, while he acual demand for any period is x. Shorages may occur when x > y. The shorage cos is π dollars per period. To place an order for procuring y iems, he fixed ordering cos is A dollars, uni purchasing cos is c dollars and uni holding cos is h dollars. Each uni brings a price of w dollars when i is sold, where w > c. Average fixed ordering cos per period is given by A/y ; while revenue earned per period is ( w c) y, he average invenory per period is h y x ). In a periodic (y, L) ( replenishmen policy, he aggregaed oal cos (TC) is given by TC = ( h )( y x ) + A y. The invenory cos and variable cos per uni per period (holding cos, seup cos, shorage coss ec.) are lised in Table 5. Holding cos rae is 30% per year. Therefore, holding cos h per monh is, h = ($5)(0.30/year)/( monhs/year) = $0.64/monh. Table 5: Uni coss applied o he invenory model Parameers Jul Aug Sep Oc Nov Dec D Acual Demand (in million, $).87 4.33 5.30 5.46 3.4.49 A ixed cos (in housand, $) 5.0 4.0 6.0 6.0 7.0 9.0 c variable cos ($) 5.0 5.0 4.0 5.0 6.0 30.0 π shorage cos ($) 5.0 5.0 5.0 5.0 5.0 5.0 h invenory cos ($) 0.64 0.64 0.64 0.64 0.64 0.64 The seps o compare he forecasing models using he invenory coss are described in he following, Sep : ind cusomer service level by specifying he probabiliy (P ) of no sock-ou using periodic review policy. Sep : Selec he safey facor z o saisfy P(Z) = (- P ). The value of uni normal variable, P(Z) can be obained from Z-able or from inverse funcion of normal disribuion. Sep 3: Deermine he ordering quaniy, Q, for each forecas using lead ime L( ŷ L ) and he safey sock (SS) where SS = Zσ L (σ L is sandard deviaion of he forecas error) Therefore, he ordering quaniy is Q = yˆ L + Zσ, L (Ordering quaniy may be increased o he nex higher ineger). Sep 4: Compue he opimal invenory cos of acual demand and demand forecass using dynamic programming (DP) algorihm. Sep 5: Calculae he relaive cos of each demand forecas wih respec o he cos derived from acual demand and choose he bes forecasing model ha gives he minimum coss. The invenory cos associaed wih acual demand is he leas invenory cos, which is considered he base cos reference o he demand forecass. The relaive percen of invenory cos (RPIC) for each forecas is deermined. These percenages for each forecas are compared and he minimum percenage value is considered he bes forecas for he seleced ime series. The sandard errors of forecas, MAPE (mean absolue percenage error), invenory coss and he percen above he leas invenory cos for each demand forecas for he given daa se are presened in Table 6. Table 6: Invenory cos for each forecasing model and acual demand 5
orecas Models Sd. Error (million) MAPE Invenory Cos (million) Relaive Percenages S-ARIMA BS-ARIMA Exponenial Smoohing (M-ES) 0.55 3.8% $666.75 7.05% 0.3 7.43% $56.46 6.99% 0.48 0.54% $695.6 3.49% 6. Conclusion In his paper an ARIMA approach is used o forecas he demand of a seasonal produc. Based on he demand paern, he S-ARIMA (0,,) (,,0) model has been idenified o be he bes fi model for he ime series. or a non saionary sochasic ime series (such as winer apparel), he forecasing model ofen becomes complicaed. In S-ARIMA model, forecas errors are incorporaed o refine he prediced value, so he model gradually improves oward he end of he ime series and provides saisfacory forecasing accuracy. There are major advanages of using Bayesian mehodology o forecas non-saionary demands. As classical ARIMA requires significanly long daa series, a Bayesian-sampling based ARIMA (BS-ARIMA) model has been proposed o forecas from incomplee daa wih missing values. In BS-ARIMA model, i is assumed ha daa poins a sage- (July o December) in 004 were unavailable. A number of non-informaive priors were used for he model parameers (α, β, τ). The poserior values of he parameers were compued numerically using he Markov Chain Mone Carlo (MCMC) simulaion and BUGS/WinBUGS sofware. A muliplicaive approach of exponenial smoohing (M-ES) echnique is considered as he base reference o forecas seasonal demand A periodic review model has been used o evaluae he invenory coss for each forecas and acknowledged he cos savings due o improved forecas. The dynamic programming algorihm is used o derive he lowes invenory cos for each demand forecas and he acual daa. Comparing he cos percenages of each demand forecas above he invenory cos of acual demand daa, sandard error, and mean absolue percen error, he analysis suggess ha he BS-ARIMA model is well-performed forecasing model for ime series and advanageous over many of he radiional forecasing models. Reference Carlin, B. and Gelfand, A.E., A Sample Reuse Mehod for Accurae Parameric Empirical Bayes Confidence Inervals, Journal Royal Sa. Soc., Ser. B 53, 89-00, 990. Congdon, P., Applied Bayesian Modeling, England: John Willey & Sons, 003. Gardner, E.S, and Diaz-Saiz, J., Seasonal adjusmen of invenory demand series: a case sudy, Inernaional Journal of orecasing, 8(): 7 3, 00. Gelman, A., Carlin J.B., Sern H.S. and Rubin, D.B., Bayesian Daa Analysis, Chapman and Hall/CRC, 004. Hyndman, R.J., The ineracion beween rend and seasonaliy, Inernaional Journal of orecasing, 0(4), 56-563, 004. Kurawarwala, A.A, Masuo H., orecasing and invenory managemen of shor life-cycle producs, Operaion Research, 44 () 3-50, 996. Makridakis, S. Wheelwrigh and Hyndman, orecasing: Mehods and Applicaions, 3rd ed. N.Y., John Wiley & Sons, 998. Miller, D.M. and Williams, D., Damping seasonal facors: Shrinkage esimaors for he X--ARIMA program, Inernaional Journal of orecasing, 0(4), 59-549, 004. 6