0 ratings0% found this document useful (0 votes) 85 views17 pagesAML
Advanced Machine Learning
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here.
Available Formats
Download as PDF or read online on Scribd
34] pea ——
Mobuce - 4
classmate
a
— I
—— [ime Senter Model — Have onty
a
eal OTe eae
| utiva rca
Time Series
Takin
g
| Mowing Atteenpe =
Unvaariate
Li
Have only Q
Average
V
variables ( date
monthaCsay 3
Umonthe)
variable (Date _¢
Yy variable)
by 4 varvable>
Aatect
of
v
2
See
dato follows ‘Teautar trilervals of time — Time Serves
coal T U
| Moclet .
Bei] Mont Gales .
| arch to Sime Should be
|_ dont $0 equally phased .
IL May 20° oh a, it pracely
| dune is everyone Ghouigt be month in series,
| July 20 mo Aste or anything or nul
: — eae
Aug 25 allewee \
ep 30 bx: Nomth Soles
i [Tan
Net
Mor
Ok. il
So May
June
xamples of Forecasting
Roumfalt " Forecaching > Bock pice forecasting.
> Gaz{* price forecaxting q 2b Ain cot.
"Petrol!Cases
Time ie
Qualitative
L- moving
! TY] Aen e
Ez Exponential
Smoothing
i ARIMA
|| t~_ARIMAK
I Trenel projections }
—_Deco position.
Combining technique 2 bur belomg model i 1 euten
| dechnigu
Teme Lrw ¢ Orderecl Lequenc “ values
Lot faualty Spectre dime _ inter val .
vatrable
| Accumption. =} Time Series
vy
\
| Shout be equally Spaced over time.
Patterns of, post Mata wilt propegale intin futfire
Cannot be used to predict random _owente (x: Texnanv’)
Looe Force, Management ugel in cat centre. Predicting :
of alle le _ unde
no.
2) Catt) “Volume forecasting 3) Economic Gerree Foreeacting -GDP-
4) Inventory & kogictich “Fore tatting 5) Workload projection. oe
duane] Cater Forecasting ) Weather Perecacti Pa
ats is piven act chaste, weekly monthly.
ja
at
ibpeitan be. “4 ete requdtemenl 4 dol
He dole
Che guilt, tov esr agate gation seggeegeli
g os ion, | ab ons
is, icing in ae Comatder ‘tag. SOMES Zs
hades
averahe 0 t_ two | tree yen gput it. But it te moteee —_ re
Qa: | en Teo 2) Jana
pa Eos ey Lop 14 mA
jer 0 CMuIccImg ) seh a0 aoe
: 2ep 20 uo
Do2u 3 Ton 21 £00
rob. _panaassone 21 sep a 600
siitrarce 2. : Miccing
yeasty ri Jaorbat oe 23 550 (kieroge f
a ai Tinto Tan 24 9 ican
© Time Gees Plot = BD aptow sof. hime Senet. Vertical axe "meaty
(Finttll cee row data -tooke.) sty» variable of inforect 9 horizonta
anc || Corresponds to dime periods
Components 04 Time Servex ¢
Season Cycles Trenc Cancreasing | decreasing.) reegular.
1 Fem
—||Prce (Product drfe Cycle) ¢
ea Taleh oe
Period
x_&
| = ‘Puriotre _ Pluctertion .
* Thend = dong Jerm change in __mean -
& Onereal ! A —_ OsceQlatiry movement in dali
a eas where the! period of ocerttation
c..—rt—S—ES typically” snot bln, 0
Vv Tclassmate,
s SS ULL
remain ter avs own
been accounted for
oinle 1 neces
or mext anontht.
o 0 td =
Mini O 4g & inl 1c meced sa
toe ean crecast for meet 41 rweebt. 7
ig recomm
no. 0. ie 30 /21 Joe
model.
dala i nececar clot
ear o,
Normal a eit not goo for dime~ feriee forecactin,
becauce im “average ual _tarportance it oven Lo.
data int. Rut a trend 6 rrent —_ugilh
end or _previove, 2/3 pointe on
Creeent:
sor | Yrelt | aa | tao [ua y [buna error ( itretd
Ser qT [Peasy aera
£3 of Sufi) oy there) | Coke
a ee )
ol6 ASG twit
el7 90 SJ 170 14
Dole 13. 1ee 14
2014 bo. Mies lea a
20 kal 172
oot 186 no
a2 lan] 1918
[}eod3 Podt} 144
oau | 2 ooo
a2
l6
le
1a,abs MAp_err | Maden abe MAderr. | any enr
= | (Yrela - Ha) Cuvetd = Hau),
4 ' .
by -3 3 2
4 =13 es a 6
2 ~4 . = 4
tell ty “ly ‘to to.
ri 1 2 7 . y a 7 a
tal. 19 | 4 22 a
tan 1310 Mean 12.83 Mean 13.73
| a
llwe nave: 3% moving dverages NAC, HA(9), MACH). te know
wivelvl| yo better fimel_ MAS _ ern, MAd-erh, MAG-enr fy find trere
chbcolute £ find re mean of absolute of errone. Yhe one
usin Deis meow cL. ‘absolute errors’ re Oia befler one.
Heap fe VO NAS. Me 9e » ef AMSA.
;
|
: oe © wu
Mua - Rogrincinre 1
2 : oe
aye iitme iene tannot | be epretenlid in Unenir regivession.
|| Becauce time Series hae. slate os + is _all, . d
y Hla ie hate, imlérvab') Hien svce dime Srmredlet
zB
Component to
--first__eleek, _for_miseing volute _or i data ict equally
—{paced Plot _eimpte.
trend chart
cet Resi
underttand better.
2 1g terme evmpunit_of otal, lovidat ean be
—_forceata.Saee ter} Be i one
ppieeeeseats penta WON oa Bor ENKI Je wes pme Model,
of dala
Tt requires good good _anount
i
I
|
dime
it. <
Rea ese ofeer eae wilhin
i
I AR - Ma
| Zoe! Nr
|| Auto Regressive Inleq-valeZl Moving Average
| Ceatuatily) CStationarity? ¢ Recency)
Rinear Regression
| Apa _modele are able to moolel_c wide Spectrus
Gries behaviour & have a £4 sternatie Approach. Foy
iderdil ying the Correct form.
| Aulo- Regressive cap tires Leoeonoli ty
She “ARIMA model aun Sequential iy first _rnodlet.
Auth - Peqreucive rune to predict & the Crror( aeftal - = pres
oil be pasted to rtibdet t Movie Arerage. Calculates
Trey
other! value? “both ) Auto - regressive 6, Moving Arerage willl
qct_rtigrali. . a
. pra dee —cdafe—for_A&_melel_€| error gentnaléa
om || AR q
{ ! smodel te__data for MA model 4
AR MA
_#\_0 on 4a
s 4 1 ©
6 5 ! \
a 2:
cong _ =
| 2 3
| I 3 2
[4
6 3 '
{ . 1 | Zclassmate 5)
Gz
egrets on :
AU ata cience wmoctele tikes Aimear, | gt
te trite to find reason: Por model
atl rows one b one. But
works vertrcalty 1c trier te fine
by examining att
uoorks horizontal
by examiniay
Series model
weacon for model. _annwertifg —
values of Coleman + tric. fe far. autho regretsive. mode).
v
Time Gerier Model
u z 3 Xo X
————
orm i t
pee =
oo 10 F do \/Ate
3 M te |\ thee
Whenever, there etre _onany bia ia [Nfe
date || pvinte _§ Fue Con observe Lore May 2h Be) ee
Sea rrcality | Gyebicat. [a those. + tune - 5)
dala points Can be comidered igri ficant v
: For He
mat oll hota porate Shave ty be
contidered im that eae.
Auto- regressive (AR) Process.
Yee et BY ye ee
Mo yi CMA) Process
ae a a Be + B2 Oyen a
uhere Ct = (fy? «2 ye) i 2s
wurxedt
Aipring Models (‘ARMA) _ Procese!
ep hfe + ha Yea onsets Cet On Cua + By Opo24.
y
oe
AR Woebke em _ Cemawitic. process’ ~ Seaton, hl
| MA -: works: om inrequbar Comnpoment (noise GB recluces
: extulgivorie
the ___ error.
:
trendCIASSMAte :
es ——$—_— — in
Three Gloge of Aen ed etm
h Identuficaiton 2. Gettmation
4:| Toenripicntyon Gage
e | ior iclentify :
I = whether Shafionary | mon = ttationanty
I = Seaonality
I = Oreler AR 6 MA processes :
: i = White Noise C Tovegutar trends vole Canna
I be predicted )
omeng
YH date’ ie mot » Streamlined average. Jen Variance
—_Nen Ctationanly \ 1 de 1 mst
Gationary Time SoNex - Gtastictical propertier euch ae
mean, Varvance, autocorrelation. cre OR hpinitont
ever time eae :
er
fn |
a
Sobor
Chart 2 Non. Stettona ny
In _ aR, i x
ce IMA Assumption 1¢ daly « Shouta be Sockiomany
: : T
ADP CAvamented Dik Bll 7
- ,.¢ ler)Tect ak an
data ic aa : ebostinnes : :
Gllonaiy te chatcomany tare
fog Cu.) Bi it becomec Oye
bhCz meen) Care ya)
Yi lags Cy) hago. ty) — aoe
2 - = Deloig Cbe.-
20 1 oa 1 tranelormation)
(fn i _ dat le) toppers Ub
J loo -14J 4
te t HY sya _forecat te
-May 5 Unia-a] wo esr) Valuer
Tune ost 6 es | 19-28)
| Joi-25)
I
=| How To Detect Seasonality
| veing | Autocorrelation Plot (ACE) Gequence plot , multiple.
I box _plott . - : ;
[
| Auto Correlation, function
ACE Plot - Bar chart of Cocfticrenls™ of Correlation duc
| time Serie $s itself.
Pack Plot ( Partial Autocorrelation funclion)
Correlation =~ Rilatiorship. bw 2 Coniinuove vanablec.
Autocorrelation fs Correlation’ Clortimucve | varvable), but
|_insthad of 2: dit forent variables , 't 1c Correlation
Lita sbetw va t fame ‘variable: ine” Yew Ye~
Ye Yt-o, Yt ~ Yeo considering - ooffect: other
[- 2 a} : varrablee on
Me af wen.
Portal Sorrefation = ‘
—— een :
(prrefetion in _blw 2 valuee of Lame variable
h the “fis of other _variablec oni Yt is not
er Ge the, orher variables cre Contint
Ale im Ye ew Yer) here we cure. finding Correlation
=o Ye 6 Ye-1 keeping other van eens.)
ant.a
classmate, |
pd ood = os al
— Tnputr oo Agima ic pda & -
== Agi map, a a4)
————_ P> Comes from. PACE Curve
t= Comes from Cationarity (ie ot whieh 4eg
| dlata becomes Stationary )
4 =) Comes from ACF curve |
| Ge: ARIMA (3,2, 4) |
“ Here, Aata becomer Stationary ot fag BLD. th “eu aa 2
the Pst bars that * Croceee’ ‘vexomen niin PACE curve |
ig Comesderea ac ps TéKe sve Of that © value - =Cmodelue)
i
ws)
¢ ae 7
iE °
7
By
— ve Here Pp
(RT le woe
() eas 6 &
= 36) Ae
Dy the: iven data itset, ig. shatienlery then .d=o0
[Thicmedel 10° ARMA rnodel :
The. bare that eroce UC or dtu
Pe Comerdered Bei: 4 walue.
det'c fey = 4,6, 6,4
“dhe mo. 4 modele Can be -permufation ». Combbinabio
Pig, de
fe Models (3, 9 a
fet M5 C35 2n6)
in ACP curve i
| C612, 4yclassmate.
=o
Testing the Forecasting Gerformance ___
—||_Mape $y 3 Rust CRoot Mean Square Error)
(Mean Absetule Percentage Error)
Chooce the model with Smallect maple, Rmse as bert
ombdet -
Stratepiec Larmptieng C Shic te for logsetic regvetsion)
Dyeide ample evhere y= ao
\ Cain m0) Cee in no) *
Train Test Trai? \ rect
! i Bor 20+-
Ceor) (20s)
data Cannot be _Qpuit__irendomly im time - Serves
motict _becauce data will not be Spaced. equally .
Usualty dost 2 quarters Cé smenths) ioiumbentoalrde ca
foil tact _datroet . Insbial CFrnet) omen for train eet.
Im Linear regression, Aolh can be epuit, randomly bat
it ig mot _ accurate. Fimel Lome echnrguec.
@ 2 p of al
ead for matter ammount f
Io. A
| Smeching Techav gue
| Seahtea Smoothing 3) Expomentiol
. pees Ymnootiung 2\_Werghleat some eng nting
I
Wludesehtza Avenaet. + Gixing omore worghbage, to recear
anonthc[“bme erick lata “while taling forecast
T
th
Key Months 0¢| Momth2.0q| Months | Month4 | Months” Lon
:
tooo || 49.eu ee 14~ | o2¢.03 [isd 213.06
tooul G&.9o0. No 82 D3e ob] Yo. 14 65 A>
teol2 || 817.44 HS6.66 bs.0¢ | 2545.99 | 4p 30.4
loots || 446.qy 743.5) | 345.67 5VS2 | 363.4
loorulll 363.04 355.5 521-6] Atom orl 454.25°
|
Thy ic ume Serves dat but in Jer of 2acW customop =
a
a
=
Here | wergnta average, if we wont i inet Menthe og of
___toorg lowe tamer. :
E be || take Gov. ph 454.95 + Qp'/ ef Low, OT+ loys of 52.6 y
. eee OS a St 355-5 +0571 of 30, 04. tones ae
= cdhille pereenlin 16 not tied , butt may Cure w give! amore
wiih 092 Lo Ye cent Cala. Percentage tho
Th Go4 204 10406 +65 _
i Tt [rs better Hor dogeCy) iL 6 lng polnle Sin
—— Sein behind Hoe writ Cause Lat ay dats Docs ,
ic mot Stationary pen Otter 6 ty
db tata tranctormeteon AS than atdhe fen
Stat added. ty fe too
Vv
loO ve
we,a
a
oF
derm Memory? Orophtt >), ethic vs when dels hat no feaconalily
dre or yet
Weighted Average will
4 4 mol_qure good retultt for nore
6
ornte , it'S better fbr Ymatler “no } data _poinlt
t
ate
gee _ExpoNentias Smooth in
Here, any number blu Ol te 0-4 cam be taker & amulti'p Wed
#
wif} previeve value im powers
Month, Geter Single. onential
ingle Exes
oT, lo to.
F ies Jo» 0.47
M 1p rn x 0.4
4 lia Ip x 0-47
NY :
May to A tax 0-4
o ~ 7
June to Fyie x 0-4
July 9 12 x 0.4!
o weight
Reduane weight in exponent’, Thc fechnique 1S applrcable
for Smaller Cet 04 ata Point becauce exponents become
ap Es exponent power ic Augh. Werghte dont even add
up| to 4 .
oneNTIAA — QmoorHiNG
tan be blw 0 to 0-4
Here, weight is added r
Un = C+ Yo + Cine) Dans det'c take Sar 0-4
U q TR Were
Bae Month Gale 9
z 3 3
E. lo (0-4 st0) +(1-0.4)S = ©
M Jo G-4 ey + C 1-0-9) Y= IT
A 13. (41 + Cl-oed tet =
— Moy a
Tune °
Tile——
to Caploine
|
Scponcatial Cmooihing faite
f
Hoare HETHOP
Pinan Capone on Savona e__
Adding Slope to -Cepomentind- Cn nga p—tes Salas) Lucre
: li mn Puy
stn which? fc _7ruse! ni exponential Smoothing
Glope 2 ms AY
a
am:
| fp = x - Ya
Two medele of Double Exponential Looting
[aaartive . Mubtipvreative
T
1
|
| Gage Exponential Werghted Gmoothin =
3 if Alpha tan be nyt: i
+2 . blu _o+! to0-4
|
i
aa
(eee)
Se 7 aie
3262 (0.9% 68+ Coty 4a) OF
[13> Oa xa) + Otx85) = 197
— 2
273) (03.4153) + (14127) 2 135
; (0.3x973) +Yxissy = He
Formula = -
mele = Oye Yay ECB) ae (alta ne vata
i af
But Oy + es = 4.
douse bx
ONENTIAL Lmoorn ING
ln 2 %a + OO) Che
eee
aes. devel
Qa eds \ + (162) bn ee|| P_tan be anything blue 0:1 “to 0.4. 0% G Pp Mean alto Gy
Sorte _Ps06 Cin ba)
4 dx bx gant
a =
10 3 ogfa-0) +Ci-0.6)0 = @ (C12) 5
Joy pie (i= 6) 4 Clec6)o - 66 16.6
is bo. 0-6 (12-") + (1-0-6) 5:6, = 9 C4 lub &
lo 4 OtGGe iso Cibo et ces 8.336
ened) 0-6 (7-4) + C06) (= 0,664) = - 0:4 344 | 6. 0656
| Teipae Exponent 1A Smoorning I Hosrs Winter HeTHoe.
|_ Alto fap tines eas aug Requires more dala poinls
Wits = ot Cys 9.24 3 Cie df ee) Kevel
bas p (ty = bas) + Up) bent —
Ly = b (yx — tad + (1-3) Seng Qatonimecas
Giuem = 4x4 mby + Sx-g¢4+ 6n-1)modé Poreath.