Deriving OLS Slope and Intercept Formulas for Simple Regression

Поделиться
HTML-код
  • Опубликовано: 18 янв 2025

Комментарии • 78

  • @andotech
    @andotech 6 лет назад +10

    This is pure gold. Thank you for not skipping any steps or combining too many steps! There are a ton of videos and documents online describing how to derive and solve these equations, and the vast majority skip steps and then I'm lost. In order to understand every detail, I need to understand every step. I do, now! Thank you!

    • @BurkeyAcademy
      @BurkeyAcademy  6 лет назад +1

      I am so glad to have helped! I am the same way, and I just make the videos I wish I had when I was trying to learn this stuff! Good luck!

  • @kevinberlanga2671
    @kevinberlanga2671 6 лет назад +2

    This is the best video explaining the derivation ever. Please teach my class

  • @15Jamus
    @15Jamus 9 лет назад

    Thank you so much for this video, you derived the OLS and explained every step you made in a much better and understandable way than my lecturer!

  • @lennyste
    @lennyste 5 лет назад

    Outstanding explanation! I just had 2 homework problems that used this "trick" of equating the sum of Xi with the sum of Xbar - I would have been lost without this video! Thanks

  • @kyliekent8583
    @kyliekent8583 5 лет назад +2

    This is such a great explanation way better then my professor!!

  • @TubularOfficial
    @TubularOfficial 4 года назад +2

    THANK YOU!!!! IM ACTUALLY GONNA CRY CAUSE I GET IT

  • @7479zm
    @7479zm 6 лет назад +1

    Really enjoyed your video. Learnt this today and I have exam tomorrow.

  • @jas-hy3sy
    @jas-hy3sy 5 лет назад +1

    For the two star equations at 19:33 .. can you show how to get from the first one to the second one?

    • @BurkeyAcademy
      @BurkeyAcademy  5 лет назад

      That's what I was doing from 19:33 - 24:00. What part wasn't clear?

    • @jas-hy3sy
      @jas-hy3sy 5 лет назад +1

      @@BurkeyAcademy you showed how to get from the second to the first and I was able to follow. Taking the equality for granted, I can work backwards. But how do I go from the first to the second? I.e. from (Yi - ȳ)Xi to (Yi - ȳ)(Xi - x̄)? The purpose of (Yi - ȳ)(Xi - x̄) is to see that it's the equation of the co-variance but without knowing (Yi - ȳ)(Xi - x̄) = (Yi - ȳ)Xi, how do I find (Yi - ȳ)(Xi - x̄) from (Yi - ȳ)Xi? Am I making sense or is the answer in front of my eyes?

    • @BurkeyAcademy
      @BurkeyAcademy  5 лет назад +2

      @@jas-hy3sy Like a lot of steps in derivations/proofs, it is hard to see how someone originally figured out that exact step-- personally I just have to convince myself that the step is true. So, as I tried to explain in the video: You have to just see that when you multiply both of these terms out: One: sum(yixi +ȳx̄-Yix̄-ȳXi) and Two: sum(yixi--ȳXi), that these are equal because the +ȳx̄ and -ȳXi cancel. Hopefully that helps- but if not, I can try again!

    • @jas-hy3sy
      @jas-hy3sy 5 лет назад

      @@BurkeyAcademy Yes that part is clear. Thank you. And yes, the manipulation of the original to get to the second seems complex. Also, at 15:54 when you went back to add the summation signs, you changed the + sum(B1x̄Xi) to - sum(B1x̄Xi), but you ended up with the correct final answer.

    • @jas-hy3sy
      @jas-hy3sy 5 лет назад

      Ok just did the calculation. The - sum(B1x̄Xi), should be + sum(B1x̄Xi), and before factoring the two terms, bring them to the right side, and then factor, to get what you got.

  • @JacobLocke
    @JacobLocke Год назад

    Hey, thanks, I spent a lot of time looking for an explanation for this (19:07), not even the most recognized econometrics books explain it (they take it for granted) =D

  • @kalubakamanga631
    @kalubakamanga631 4 года назад

    Your videos are extremely helpful.Thank you so much

  • @colinhendricks1186
    @colinhendricks1186 10 лет назад +4

    Can you watch 15:30-16:10 again please? I believe you may have accidentally switched the + E(B1*x-bar*Xi) to - E(B1*x-bar*Xi) when you are putting the summation signs (which I have represented with "E") into the equation. Would this change anything that follows?

    • @BurkeyAcademy
      @BurkeyAcademy  10 лет назад +2

      Thanks for the catch. I added an annotation. The "+" sign is correct, and my writing the "-" down wasn't carried through to the next line. If you multiply out the collected term in the line below, you will get a plus sign back out of it.

  • @Esraberry
    @Esraberry 7 лет назад +1

    Well explained , perfectly helpful 🙏🏻

  • @felipebauer223
    @felipebauer223 5 лет назад

    Thank you from Brazil!

  • @TheJohnlennon1989
    @TheJohnlennon1989 10 лет назад +1

    At 17:41 I think you may have got them the wrong way around (shouldn't it be *sum of beta 1 multiplied by x bar minus xi (in brackets) multiplied by xi*? multiplying out gives the *sum of xixi minus the sum of x bar xi*...whereas in the previous expression it's the *sum of x bar xi minus the sum of xixi*? Or does this order not matter? Thanks - videos are v.helpful btw.

    • @BurkeyAcademy
      @BurkeyAcademy  10 лет назад +1

      Thanks for the nice comment. As to the question: Since that term has a leading minus sign in front of it: -S[B1(xi-xb)xi], when you multiply it out you get -SB1xixi - - SB1xbxi. So the two negatives cancel. Does that help answer your question? [It is hard to discuss this using text and timestamps, isn't it? ☺ ]

    • @paperboy42190
      @paperboy42190 10 лет назад

      BurkeyAcademy I think Ofir Hughes is right. However the mistake isn't evident because it just corrected for your +/- sign mistake earlier on.

  • @amkan1797
    @amkan1797 9 лет назад +2

    perfectly explain! Thank you !

  • @deborahsakazhila4068
    @deborahsakazhila4068 4 года назад +1

    Hey! How would you derive the OLS estimates for multiple regression?

    • @BurkeyAcademy
      @BurkeyAcademy  4 года назад +2

      It is really the same thing, except it gets very tedious unless you do it with matrix algebra. You could add a B2*X2i, take three derivatives, and solve three equations for three unknowns. Using Matrix algebra instead though, you find the solution is B-hat=(X'X)^(-1)(X'Y).

  • @cecileboulanger6103
    @cecileboulanger6103 7 лет назад

    Thank you so much i finally get it can't thank you enough

  • @aloicemwamidi8560
    @aloicemwamidi8560 6 лет назад

    This was really helpful. Thank you.

  • @juanbravo5315
    @juanbravo5315 4 года назад

    can someone explain me how to get at min 17:26 sumatory of (xi - x_bar)? woudn't It be sum(x_i + x_bar)?

    • @BurkeyAcademy
      @BurkeyAcademy  4 года назад

      As I noted in the video description: Note: At 16:05 when I add the Sigma, I accidentally write down a "-" in front of it. This should be a +, but this error does not carry through to the rest of the video.

  • @John-dw6jb
    @John-dw6jb 3 года назад

    Amazing video thank you so much..

  • @shielamaetaotao3166
    @shielamaetaotao3166 6 лет назад

    thanks for this video. it unloaded some of my burden

  • @salehganassou568
    @salehganassou568 9 лет назад +4

    it's really helpful ,thanks a lot for sharing ,and may allah bless you

  • @aladoanitaelorm5848
    @aladoanitaelorm5848 5 лет назад

    we explained. Thank you soo much

  • @MarceloSido
    @MarceloSido 3 года назад

    fantastic video

  • @Vjjehhaghvjhgahff6692
    @Vjjehhaghvjhgahff6692 7 лет назад +2

    thank you

  • @ashishakshantal1868
    @ashishakshantal1868 7 лет назад

    at 16:08 while distributing the summation, you have changed the (+) to (-), shouldnt that be (+)

    • @BurkeyAcademy
      @BurkeyAcademy  7 лет назад +1

      Yes, thanks for the catch- sorry for that! I have a note in the video description alerting people to this mistake- but aI know this is not a perfect fix. I hope one day my health and energy level will get better, so I don't make so many silly mistakes! Again. I thank you very much for catching my mistake. I'll go back and edit the original video and upload a better version.

  • @johnhobson2106
    @johnhobson2106 7 лет назад

    Really helpful, thank you!

  • @bushrahaider5179
    @bushrahaider5179 5 лет назад

    Well explained
    Thank you

  • @arnoldsalami8751
    @arnoldsalami8751 2 года назад

    This has been helpful, Pls can you do a video explaining the derivation of OLS estimators in Multiple linear regression WITHOUT using matrix algebra

  • @YomiDauda
    @YomiDauda 7 лет назад

    Hi BurkeyAcademy! There were two B (Betas). How did you resolve it to One? Please explain... That's the only 1 thing remaining for me to get it fully. Thanks in Advance.

    • @BurkeyAcademy
      @BurkeyAcademy  7 лет назад

      Can you give me an approximate time (minutes & seconds) in the video where I did this? That way I can make sure I am focusing on the right part.

    • @YomiDauda
      @YomiDauda 7 лет назад

      At 17:26

    • @BurkeyAcademy
      @BurkeyAcademy  7 лет назад

      Simple case: a*b-a*c= a*(b-c) [multiply it back out to see that this is the same]. More complicated: If a*b*c*d-a*b*c*c = a*b*c*(d-c). Similarly, here I take sum(Bi*xi*xbar)-sum(Bi*xi*xi)=sum(Bi*xi*(xi-xbar), which I write as sum(Bi*(xi-xbar)*xi. Does that help?

  • @elale954
    @elale954 9 лет назад

    how can we be sure that the results are the min and not the max, is it possible to prove?

    • @BurkeyAcademy
      @BurkeyAcademy  9 лет назад +1

      +alejandro cuartas 1) There will not be a finite maximum, 2) Yes you could prove it, by checking the second order conditions, e.g. see www.sjsu.edu/faculty/watkins/2ndOrder.htm

    • @elale954
      @elale954 9 лет назад

      +BurkeyAcademy Thank you very much, getting into lots of trouble when I start using second order condition to prove, will keep on trying with D-test.... Warm regards and thanks again, great vid!

  • @mastaniec9149
    @mastaniec9149 3 года назад

    I have assignments to complete. I want to get answers from you for that assignment. Can you help me and how can I send you that assignment to get answers☺️

    • @BurkeyAcademy
      @BurkeyAcademy  3 года назад

      Sure, I can help you cheat- for the low, low price of $100,000 US. ☺

  • @thivyanagamuthu6963
    @thivyanagamuthu6963 8 лет назад

    this is great, thanks!!!

  • @jonathanlogrono8488
    @jonathanlogrono8488 2 года назад

    is this true if we know that the intercept is equal to 0?

    • @BurkeyAcademy
      @BurkeyAcademy  2 года назад

      Of course, but there is also an easier way in that case, which I have a video on.

  • @abzfarooq3510
    @abzfarooq3510 4 года назад

    this is some black magic

  • @thetruereality2
    @thetruereality2 6 лет назад

    Thank you kind sir 🙏

  • @torigreenaway192
    @torigreenaway192 8 лет назад +1

    Thanks alot

  • @marianaperdigao3162
    @marianaperdigao3162 8 лет назад

    thank you so much!

  • @anthonyruiz1470
    @anthonyruiz1470 10 лет назад

    Thanks for the great video.
    I know this is probably something rather insignificant but I'd like to understand the logic rather than memorize this step.
    When you do the chain rule and take both derivatives with respect to Bo and B1 why are the outsides of each equation multiplied by -1 and -Xi?
    I completely understand how the chain rule works but Im just not understanding how the derivative of the interior is -1 and -Xi...
    Please help quickly.. Thanks in advance!

    • @BurkeyAcademy
      @BurkeyAcademy  10 лет назад

      Just simple chain rule... f(g(x))-- f(•) is squaring. So, derivative of that multiplies by the 2 and subtracts one from the exponent. Then take the derivative of the inside and multiply by it: The -B1xi in the first case and the -Bo in the second case. Does that help?

    • @renisalamander
      @renisalamander 9 лет назад

      +BurkeyAcademy I have the same concern. As for -B1xi, I am approaching the problem as if I must use the product rule, namely (-B1)'(xi)+(-B1)(xi)'? I am a bit confused. At 5:45, I am not seeing how the last part of the chain for (-B1xi)' is simply -xi. Any help is appreciated.

    • @BurkeyAcademy
      @BurkeyAcademy  9 лет назад

      Roughly speaking, the chain rule says that the derivative of f(g(b)) w.r.t. b is df/dg * dg/db. Here the f(•) is the square function, and g(•) is [y-bo-b1x]. So, df/dg = 2[y-bo-b1x] and the derivative of [y-bo-b1x] w.r.t. b1 is (-x). Are you suggesting we multiply the squared term out? In that case, with the product rule, you'd have -x•[y-bo-b1x]+ [y-bo-b1x]•-x=2[y-bo-b1x][-x], the same thing... If it still isn't clear, please try to let me know how I can help clarify!

    • @renisalamander
      @renisalamander 9 лет назад

      Thank you for the clarification.
      I realized that I just needed to review partial derivation again to understand where I went wrong.
      Slowly making progress into the econometrics universe, over here. My textbook is a bit short of proofs so I am appreciative of you for taking the time to make the video and respond. Thanks a bunch.

    • @BurkeyAcademy
      @BurkeyAcademy  9 лет назад

      No problem- It is pretty hard to either make a book or a class that gives all of the intuition, mathematics, and applied know-how that students need. Books are either way too applied, or way too mathematical. Let me know if you need help tracking anything down.

  • @kevinseeam4849
    @kevinseeam4849 4 года назад

    you are great

  • @hetvishah5045
    @hetvishah5045 6 лет назад +1

    Does it bother anyone that he sort of sounds like Robert Downey Jr?
    I like it😂

  • @randomvideos3628
    @randomvideos3628 9 лет назад

    nicely explained.. but just throw in a little more speed without missing any intermediate steps.. :)

  • @omarabukar8217
    @omarabukar8217 6 лет назад

    It's help full sir, but i don't see the PDF of OLS
    How I get it Sir
    Thank you for such kind of Explanation👌👍

    • @BurkeyAcademy
      @BurkeyAcademy  6 лет назад

      As I said at As I said at 6:00, go to my website and click under FILES. Or, to make it easier, I included a link in the video description.

    • @omarabukar8217
      @omarabukar8217 6 лет назад

      @@BurkeyAcademy Many thanks Sir
      I get it 👍👍👍

  • @ahsanhabibj0y
    @ahsanhabibj0y 6 лет назад

    Your voice sounds a lot like Robert Downey Jr.

    • @BurkeyAcademy
      @BurkeyAcademy  6 лет назад

      One more vote for Iron Man... I think that makes it 20 for him, versus only 4 for Tom Hanks! ☺

  • @asalifewkibamo4885
    @asalifewkibamo4885 5 лет назад

    10q it is easiest way!!

  • @theodor574
    @theodor574 5 лет назад

    Horrible