Models, Errors and the Normal Distribution

0.0(0)
studied byStudied by 0 people
0.0(0)
full-widthCall with Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/16

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai

No study sessions yet.

17 Terms

1
New cards

Formula

Error =

Error = Data - Model

𝑒𝑟𝑟𝑜𝑟𝑖 = 𝑦𝑖ŷ𝑖

2
New cards

Mode as measuring error

ŷ𝑖

  • The most common value

  • A very simplified measure

3
New cards

Mean as measuring error

  • Summing all data points then dividing by number of data points - Ȳ represents the mean.

  • Looks at the average value.

  • Poor measure of error - allows values to cancel each other out.

<ul><li><p>Summing all data points then dividing by number of data points - Ȳ represents the mean.</p></li><li><p>Looks at the average value.</p></li><li><p>Poor measure of error - allows values to cancel each other out.</p></li></ul><p></p>
4
New cards

Squared error as measuring error

𝑒𝑟𝑟𝑜𝑟𝑖 = (𝑦𝑖ŷ𝑖)2

Can only be positive because you're squaring it.

5
New cards

Sum Squared Error (SSE) as measuring error

Sums all of the data points

<p>Sums all of the data points</p>
6
New cards

Mean Squared Error (MSE) as measuring error

  • Often seen being used in model fitting literature.

  • Sum of all the squares divided by number of data points.

  • Problem with units being squared.

<ul><li><p>Often seen being used in model fitting literature.</p></li><li><p>Sum of all the squares divided by number of data points.</p></li><li><p>Problem with units being squared.</p></li></ul><p></p>
7
New cards

Root Mean Squared Error (RMSE) as measuring error

Unit generated makes the most sense in measuring the model error.

<p>Unit generated makes the most sense in measuring the model error.</p>
8
New cards
<p>Model A: Judge this model</p>

Model A: Judge this model

  • Equation: ŷ𝑖 = 𝑖 ∗ 𝑎𝑔𝑒𝑖

  • Takes into account that there actually are differences across age.

  • Model for each data point now depends on age of the specific child, multiplied by a parameter (the slope of the blue line).

  • Problem that this model goes through 0 - no child born at 0cm.

<ul><li><p><strong><span>Equation</span></strong><span>: ŷ</span><sub>𝑖</sub> = <span>B̂</span><sub>𝑖</sub> ∗ 𝑎𝑔𝑒<sub>𝑖  </sub></p></li><li><p>Takes into account that there actually are differences across age.</p></li><li><p>Model for each data point now depends on age of the specific child, multiplied by a parameter (the slope of the blue line).</p></li><li><p>Problem that this model goes through 0 - no child born at 0cm.</p></li></ul><p></p>
9
New cards
<p>Model B: Judge this model</p>

Model B: Judge this model

  • Equation: ŷ𝑖 = 0 + 1 ∗ 𝑎𝑔𝑒𝑖

  • Adds a constant - good job at explaining data, but could be split into other factors.

<ul><li><p><strong><span>Equation</span></strong><span>: ŷ</span><sub>𝑖</sub> = <span>B̂</span><sub>0 </sub>+ <span>B̂</span><sub>1</sub> ∗ 𝑎𝑔𝑒<sub>𝑖  </sub></p></li><li><p>Adds a constant - good job at explaining data, but could be split into other factors.</p></li></ul><p></p>
10
New cards
<p>Model C: Judge this model</p>

Model C: Judge this model

  • Equation: ŷ𝑖 = 0 + 1 ∗ 𝑎𝑔𝑒𝑖

  • Equation: ŷj = 2 + 3 ∗ 𝑎𝑔𝑒j

  • Two separate models.

  • Estimating slope and adding a constant for both male and female.

<ul><li><p><strong><span>Equation</span></strong><span>: ŷ</span><sub>𝑖</sub> = <span>B̂</span><sub>0 </sub>+ <span>B̂</span><sub>1</sub> ∗ 𝑎𝑔𝑒<sub>𝑖  </sub></p></li><li><p><strong><span>Equation</span></strong><span>: ŷ</span><sub>j</sub> = <span>B̂</span><sub>2 </sub>+ <span>B̂</span><sub>3</sub> ∗ 𝑎𝑔𝑒<sub>j</sub></p></li><li><p>Two separate models.</p></li><li><p>Estimating slope and adding a constant for both male and female.</p></li></ul><p></p>
11
New cards
<p>Model D: Judge this model</p>

Model D: Judge this model

  • ŷ𝑖 = 0 + 1 ∗ 𝑎𝑔𝑒𝑖

  • ŷj = 2 + 3 ∗ 𝑎𝑔𝑒j

  • ŷ𝑖 = Ȳ

<ul><li><p><span>ŷ</span><sub>𝑖</sub> = <span>B̂</span><sub>0 </sub>+ <span>B̂</span><sub>1</sub> ∗ 𝑎𝑔𝑒<sub>𝑖  </sub></p></li><li><p><span>ŷ</span><sub>j</sub> = <span>B̂</span><sub>2 </sub>+ <span>B̂</span><sub>3</sub> ∗ 𝑎𝑔𝑒<sub>j</sub></p></li><li><p><span>ŷ</span><sub>𝑖</sub> = <span>Ȳ</span></p></li></ul><p></p>
12
New cards

Equation for a normal distribution

𝑁(𝜇, 𝜎2)

𝜇 - specifies where centre of the distribution is placed.

𝜎2 - how wide the distribution is.

13
New cards

Likelihood equation

  • 𝑃(𝑥|𝜇, 𝜎2)

    • Probability of obtaining a certain value - $x$ - given the two parameters in the model.

    • Circled point closer to the middle - highly likely, compared to lower circled point.

    • Can take all data points and multiply probabilities together to get likelihood of the data set - 𝑃(𝑥1|𝜇, 𝜎2) * 𝑃(𝑥2|𝜇, 𝜎2) * 𝑃(𝑥3|𝜇, 𝜎2)

<ul><li><p>𝑃(𝑥|𝜇, 𝜎<sup>2</sup>)</p><ul><li><p>Probability of obtaining a certain value - $x$ - given the two parameters in the model.</p></li><li><p>Circled point closer to the middle - highly likely, compared to lower circled point.</p></li><li><p>Can take all data points and multiply probabilities together to get likelihood of the data set - 𝑃(𝑥<sub>1</sub>|𝜇, 𝜎<sup>2</sup>) * 𝑃(𝑥<sub>2</sub>|𝜇, 𝜎<sup>2</sup>) * 𝑃(𝑥<sub>3</sub>|𝜇, 𝜎<sup>2</sup>)</p></li></ul></li></ul><p></p>
14
New cards

Log likelihood equation

Uses logarithm to describe the likelihood equation

<p>Uses logarithm to describe the likelihood equation</p>
15
New cards

Maximising likelihood = …

Minimising MSE

16
New cards

Minimising MSE = …

Maximising likelihood

17
New cards