You are on page 1of 25

Universitas Gadjah Mada

Fakultas Teknik
Departemen Teknik Sipil dan Lingkungan

VARIABEL RANDOM
Statistika dan Probabilitas

Pengertian
2

Random variable (variabel acak)


q

Jenis
q
q

suatu fungsi yang didefinisikan pada sample space


Discrete random variables
Continuous random variables

Contoh
q
q

jumlah hari hujan selama 1 tahun diskrit


jumlah (volume) hujan selama 1 tahun kontinu

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Variabel Random
3

Notasi
q
q

X variabel random
x nilai variabel random

Fungsi
q
q

Suatu fungsi variabel random adalah variabel random pula


Jika X adalah variabel random, maka Z = f(X) adalah juga variabel random

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Variabel Random Diskrit


4

q
q

= discrete random variables


= x1, x2, x3, , xn
fX(x1)
fX(x2)

probabilitas fX(xi) = 1

fX(x3)
fX(xn)

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

fX(xi)

distribusi probabilitas diskrit


x1 x2 x3

xn1 xn

distribusi probabilitas kumulatif


diskrit

FX(xi)
0
5

x1 x2 x3

http://istiarto.staff.ugm.ac.id

xn1 xn

probabilitas
x xi
Variabel Random

18-Oct-16

q Distribusi probabilitas kumulatif


suatu variabel random X untuk X = x
FX (x ) =

f X (x i )

xi x

q Distribusi probabilitas
suatu variabel random X untuk X = x
fX (xi ) = FX (xi ) FX (xi 1 )

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Frekuensi relatif
fx i = Fx i Fx i 1

Probabilitas
fX (xi ) = FX (xi ) FX (xi 1 )

Frekuensi relatif kumulatif


Fx i (x ) =

fx
j =1

http://istiarto.staff.ugm.ac.id

FX (x ) =

fX (xi )

xi x

Variabel Random

18-Oct-16

Variabel Random Kontinu


8

Probabilitas
n
prob(A ) = i = fx i
n

ni = jumlah data di klas ke-i


n = jumlah seluruh data

Dengan demikian fxi dapat dipandang sebagai nilai estimasi probabilitas


fxi estimasi prob (A)
histogram frekuensi pendekatan distribusi probabilitas
frekuensi kumulatif pendekatan distribusi probabilitas kumulatif

http://istiarto.staff.ugm.ac.id

variabel random
kontinu diperlakukan
seolah-olah variabel
random diskrit

Variabel Random

18-Oct-16

pX(x)

luas =
prob(X b)

luas = 1
luas =
prob(a X b)

1
PX(x)
PX(b)
PX(a)
0
9

pdf = probability density function

cdf = cumulative probability


distribution function
prob(a X b)
a

http://istiarto.staff.ugm.ac.id

PX(x) = prob(X x)

x
Variabel Random

18-Oct-16

pX(x) = probability density function of a continuous random variable


PX(x) = cumulative probability distribution function
x

PX (x ) = prob (X x )

d PX (x ) = pX (x ) d x

PX (x ) =

pX (t )dt

10

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Beberapa Sifat Probabilitas


11

(1)

(5) prob(a X b ) = pX (t )d t = PX (b ) PX (a )

pX (x ) 0, x

(2)

p X (x ) d x = 1

(6) prob(X = c ) = pX (t )d t = PX (c ) PX (c ) = 0

(3)

PX ( ) = 0

(4)

PX (+ ) = 1

prob (a X b ) = prob (a < X b ) = prob (a X < b ) = prob (a < X < b )

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Kala Ulang (Return Period)


12

prob (X a ) = prob (X > a )


q

Jadi dalam definisi kala ulang


a. suatu kejadian yang menyamai atau melampaui suatu nilai tertentu
b. suatu kejadian yang melampaui suatu nilai tertentu

Kedua definisi, a dan b, adalah sama mengingat probabilitas suatu


kejadian (event) menyamai suatu nilai tertentu bernilai nol

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Contoh #1
13

Diketahui suatu variabel random X memiliki fungsi kerapatan probabilitas (pdf)


sbb.
x 2

p X (x ) =
0

q
q
q
q

untuk 0 < x < 2


untuk nilai x yang lain

Gambarlah pdf tersebut


Tunjukkan bahwa prob(0 < X < 2) = 1
Hitunglah prob(X < 1.5)= PX(1.5)
Hitunglah prob(0.5 < X < 1.5)

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Contoh #2
14

Pengolahan data annual series curah hujan harian maksimum, H mm, di suatu stasiun ARR
(Automatic Rainfall Recorder) menunjukkan bahwa sebaran probabilitas suatu besaran
curah hujan, pH(h), dapat dinyatakan dengan suatu fungsi (pdf) sbb.
1
75
1
(100 h)
pH (h ) =
3750

q
q
q

untuk 0 < h < 50


untuk 50 < h < 100
untuk nilai h yang lain

Gambarlah pdf tsb.


Carilah fungsi cdf berdasarkan pdf tsb.
Hitunglah prob(40 mm < H < 60 mm)

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Bivariate Distributions
15

Pada bahasan sebelumnya, variabel random adalah variabel tunggal


(univariate distribution)
Pada bahasan berikut ini, variabel random terdiri dari dua variabel
(bivariate distributions)
q

Apabila kita ingin mempelajari perilaku dua atau lebih variabel random, maka
kita perlu menghitung probabilitas gabungan atau probabilitas bersama (joint
probabilities)
Probabilitas gabungan pdf gabungan

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Bivariate Distributions
16

Probabilitas gabungan, probabilitas bersama


pX ,Y (x , y ) =

PX ,Y (x , y )
x y

PX ,Y (x , y ) = prob (X x Y y )

pdf
cdf

+ +

pX ,Y (s, t )dt d s

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Bivariate Distributions
17

Beberapa sifat bivariate distribution


PX ,Y (x , )

cdf variabel random X saja (univariate)

PX ,Y ( , y )

cdf variabel random Y saja (univariate)

pX ,Y (x , y ) 0

PX ,Y (+ ,+ ) = 1
PX ,Y ( , y ) = PX ,Y (x , ) = 0

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Distribusi Marginal
18

Dua variabel random X dan Y


q
q

Ingin diketahui perilaku variabel X tanpa mempertimbangkan nilai variabel Y


Densitas marginal (pdf) dan distribusi kumulatif marginal (cdf)
pX ,Y (x , y ) pX (x )
+

p X (x ) =

pX ,Y (x , t )d t

pdf
http://istiarto.staff.ugm.ac.id

PX ,Y (x , y ) PX (x )
PX (x ) = PX (x , ) = prob (X x Y ) = prob (X x )
x +

pX ,Y (s, t )dt d s = pX (s)d s

cdf
Variabel Random

18-Oct-16

Distribusi Marginal
19

Dua variabel random X dan Y


q

Untuk variabel Y
pX ,Y (x , y ) pY (y )
+

pY (y ) =

pX ,Y (s, y )d s

pdf
http://istiarto.staff.ugm.ac.id

PX ,Y (x , y ) PY (y )
PY (y ) = PY ( , y ) = prob (X Y y ) = prob (Y y )
y +

pX ,Y (s, t )d s dt = pY (t )dt

cdf
Variabel Random

18-Oct-16

Distribusi Bersyarat (Conditional Distributions)


20

Dua variabel random X dan Y


q

Ingin diketahui perilaku variabel X yang bergantung pada variabel Y


n
n

Distribusi X jika Y = y0
Distribusi Y jika x1 X x2

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Distribusi Bersyarat (Conditional Distributions)


21

p (x , t ) d t

p (x y di dalam S ) =
p (t )dt
prob(x di dalam R y di dalam S ) = p (x y di dalam S )d x
X ,Y

X ,Y

XY

pX ,Y (x , y 0 )
yang lebih sering dituliskan
pY (y 0 )
p (x , y )
pX Y (x y ) = X ,Y
pY (y )
pX Y (x y = y 0 ) =

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Independence
22

Variabel random X dan Y


q

X dan Y independence jika


pX Y (x y ) bukan fungsi y
pX Y (x y ) = pX (x )

Joint probabilities
n

Perkalian densitas marginal kedua variabel

pX ,Y (x , y ) = pX (x ) pY (y )

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Contoh
23

Data jumlah hari yang memiliki temperatur udara rerata (TC) dan kelembaban udara relatif (H%) di suatu
stasiun klimatologi

Kelembaban relatif, H%

Temperatur udara, TC
22-24

24-26

26-28

28-30

30-32

32-34

0 20

20 40

12

30

40 60

15

30

60

30

20

60 - 80

25

17

11

80 - 100

12

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

Contoh
24

Dari tabel temperatur udara dan kelembaban udara tsb.


q
q
q
q
q

pdf (gabungan)
pdf marginal dan cdf marginal temperatur udara rerata
pdf marginal dan cdf marginal kelembaban udara relatif
probabilitas temperatur udara berkisar pada 28C s.d. 30C
probabilitas temperatur udara berkisar pada 28C s.d. 30C pada saat
kelembaban udara relatif 60% s.d. 80%

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

25

http://istiarto.staff.ugm.ac.id

Variabel Random

18-Oct-16

You might also like