All language subtitles for 02 - Use a uniform distribution

af Afrikaans
ak Akan
sq Albanian
am Amharic
hy Armenian
az Azerbaijani
eu Basque
be Belarusian
bem Bemba
bn Bengali
bh Bihari
bs Bosnian
br Breton
bg Bulgarian
km Cambodian
ca Catalan
ceb Cebuano
chr Cherokee
ny Chichewa
zh-CN Chinese (Simplified)
zh-TW Chinese (Traditional)
co Corsican
hr Croatian
cs Czech
da Danish
nl Dutch
en English
eo Esperanto
et Estonian
ee Ewe
fo Faroese
tl Filipino
fi Finnish
fr French
fy Frisian
gaa Ga
gl Galician
ka Georgian
de German
el Greek
gn Guarani
gu Gujarati
ht Haitian Creole
ha Hausa
haw Hawaiian
iw Hebrew
hi Hindi
hmn Hmong
hu Hungarian
is Icelandic
ig Igbo
id Indonesian
ia Interlingua
ga Irish
it Italian
ja Japanese
jw Javanese
kn Kannada
kk Kazakh
rw Kinyarwanda
rn Kirundi
kg Kongo
ko Korean
kri Krio (Sierra Leone)
ku Kurdish
ckb Kurdish (Soranรฎ)
ky Kyrgyz
lo Laothian
la Latin
lv Latvian
ln Lingala
lt Lithuanian
loz Lozi
lg Luganda
ach Luo
lb Luxembourgish
mk Macedonian
mg Malagasy
ms Malay
ml Malayalam
mt Maltese
mi Maori
mr Marathi
mfe Mauritian Creole
mo Moldavian
mn Mongolian
my Myanmar (Burmese)
sr-ME Montenegrin
ne Nepali
pcm Nigerian Pidgin
nso Northern Sotho
no Norwegian
nn Norwegian (Nynorsk)
oc Occitan
or Oriya
om Oromo
ps Pashto
fa Persian
pl Polish
pt-BR Portuguese (Brazil)
pt Portuguese (Portugal)
pa Punjabi
qu Quechua
ro Romanian
rm Romansh
nyn Runyakitara
ru Russian
sm Samoan
gd Scots Gaelic
sr Serbian
sh Serbo-Croatian
st Sesotho
tn Setswana
crs Seychellois Creole
sn Shona
sd Sindhi
si Sinhalese
sk Slovak
sl Slovenian
so Somali
es Spanish
es-419 Spanish (Latin American)
su Sundanese
sw Swahili
sv Swedish
tg Tajik
ta Tamil
tt Tatar
te Telugu
th Thai
ti Tigrinya
to Tonga
lua Tshiluba
tum Tumbuka
tr Turkish
tk Turkmen
tw Twi
ug Uighur
uk Ukrainian
ur Urdu
uz Uzbek
vi Vietnamese
cy Welsh
wo Wolof
xh Xhosa
yi Yiddish
yo Yoruba
zu Zulu

Original subtitles

- Many business cases,

analyze events that are not equally likely.

Some products are more popular than others

and your website gets more visitors

in certain parts of the day and less than others.

In this movie, I will show you

how to generate random values

when all of the events are equally likely.

Such as in a random drawing.

This is called the uniform distribution.

And if there are four possible outcomes,

values 1 through 4, then in the uniform distribution,

the probability of each would be 25%.

Now over time, it is very unlikely

that you will have the same number of values exactly.

However, they will be close.

And here is one case,

where I did a random generation of numbers from 1 to 4.

And here you see the actual results.

So as with most things in life,

theory and practice are often close, but do diverge.

Now switch over to Excel and I will show you

how to work with values that are uniformly distributed.

The Excel workbook that I'm using is 04_02_Uniform.

And you can find it in the chapter four folder

of the exercise files collection.

And for this, I have laid out a spreadsheet

and I will perform a number of calculations.

Let's say that I want to have a minimum value of 1.

So I'll type that in cell B3. Then enter.

And a maximum value of 6.

So type 6. And enter.

And our number of values I know is 6,

but if I want to calculate it,

I can do equal,

B4 minus B3 plus 1.

And that's because I am subtracting the value in B3,

which in this case is 1.

So I need to add 1 back, otherwise I would get 5.

So I'll press enter.

And enter again to move down to cell B7.

If I want to generate a random number

that is a random whole number or integer,

between 1 and 6,

then I can use the function RANDBETWEEN.

In B7, I will type equal.

And then the function is RANDBETWEEN.

And the bottom value is in B3. Comma.

Top value in B4.

Right parenthesis and enter.

And I get the value of 3.

Now for 'Value 2', I will do the same thing.

So I'll do equal,

RANDBETWEEN.

Excuse me. I started typing in the numbers directly

but it's better to use a cell reference

so you can change the values

without having to edit a formula.

So that's B3 for the bottom value.

And then comma. Top value's in B4.

Right parenthesis and enter.

And my worksheet recalculated,

so I have both 4 and 3.

Now I can calculate the probability of getting 'Value 1'.

So I will go over to cell E3.

And here because I know that I have a uniform distribution,

that every value is equally likely.

So I will and cell E3, type an equal sign then 1,

because I'm only looking for one value

and divide that by the number of values.

Which is in cell B5.

Enter.

And I get a probability of 0.166 repeating.

So 1/6th of the time.

Which matches our six possible values.

If I want to calculate

the probability of 'Value 1' or 'Value 2',

then that would be equal, 1,

divided by the number of values,

which again is in B5.

Plus 1, divided by B5 again.

'Cause I'm looking at two distinct values.

Enter and I get 0.33.

And yes it is possible that the randomly generated values

in cells B7 and B8 could be the same.

In which case the probability of 'value 1' or 'value 2'

would be the same as getting a single value.

But I'm working in the abstract here,

as opposed to, with the specific value in B7 and B8.

If you want to calculate the probability of getting

neither 'Value 1' or Value 2',

then you would subtract the probability

of the positive outcome, from 1.

So, in cell E7, I'll type equal.

And it'll be 1 minus, the value in E5.

Enter.

And we get 0.666,

repeating.

So about 2/3rds of the time, which makes sense.

Four out of six times,

you will not get one or two distinct values.

And that will happen about 2/3rds of the time.

So our value is correct.

And I have saved cell B10 for last,

because I want to show you another way

to generate random numbers between 0 and 1.

And this is a 16 digit decimal.

So in B10, I'll type, equal,

and then rand.

Followed by an open and closed parentheses.

And this value will be a random number,

a decimal number between zero and one.

So enter. And there we get 0.81534.

And the number is actually larger than that.

So if I click cell B10.

And go to the home tab and click increase decimal,

you can see that the value increases.

So what is the probability

of generating this specific value?

It is effectively zero.

There are so many decimal points here.

And I'm just estimating,

let's say there are 12 digits there.

If we look at 12 digits or 13 that would be in the billions.

So the probability of getting

exactly this value, is extremely low.

And if I press F9 to recalculate, I get a different value.

And again.

And the probability of those values repeating,

is so small, it's not worth worrying about.

So I hope that this movie has given you an introduction

to working with random numbers,

both as integers and as decimal values between, 0 and 1.

Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.