Polynomial fitting | Polyfit | Scientific computing with Python

Поділитися
Вставка
  • Опубліковано 5 жов 2024

КОМЕНТАРІ • 54

  • @androkranjcevic1988
    @androkranjcevic1988 3 роки тому

    Very nice video, thanks a lot!

  • @somnath1235
    @somnath1235 4 роки тому

    Thank you so much for explaining in simple words

  • @mikeh2405
    @mikeh2405 4 роки тому

    Thanks for the great video, Jisha!

  • @maariaDDS
    @maariaDDS 4 роки тому

    thank for your video! I'm having a course about python.. very helpful!

  • @ishbhatnagar1990
    @ishbhatnagar1990 4 роки тому

    thnx for this very insightful view , learned a lot .

  • @KulbirAhluwalia
    @KulbirAhluwalia 4 роки тому

    Amazing explanation!!
    More videos please!!

  • @rajanbabur4796
    @rajanbabur4796 4 роки тому

    It is very helpful. Thank you for sharing

  • @narjesspring4217
    @narjesspring4217 4 роки тому

    simple and understandable, thanks

  • @stepangavrilov8070
    @stepangavrilov8070 4 роки тому

    Wow, the best explanation ! Before that I didn t understand for a long time

  • @alandaca
    @alandaca 4 роки тому

    Great video, helped a lot, thank u

  • @Gustavo_0107
    @Gustavo_0107 3 роки тому

    Great video! One question, how do I determine the uncertainty of the coefficients produced by polyfit or scipy.optimize?

  • @sandeepgodiyal5686
    @sandeepgodiyal5686 3 роки тому

    Hello Gud afternoon. I have a data file and I want to do polynomial (4-5 degree) fit and need regression coefficients to be calculated, can you please help me in this.

  • @sachinrajpandey5242
    @sachinrajpandey5242 4 роки тому

    Ma'am I didn't find your video on sine and cosine fit about which you are talking in this video. Also can you please explain about p-value, chi square value and R-value, residue analysis which we normally talk about when we do curve fitting. Please reply. Also is there any video on Lorentzian or Gaussian fit.

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  4 роки тому

      Thank you for your message! I don't have a video on sinusoidal fit. It is quite straight forward. The things you are asking are more about statistical analysis and little bit more advanced. We will deal with them at some point in the future.

  • @paulbrown5839
    @paulbrown5839 4 роки тому

    Nice video! How about one on fitting cubic splines in Python?

  • @ganesharya3512
    @ganesharya3512 2 роки тому

    how can do it for multiple independent variables

  • @Radhika-wv2uc
    @Radhika-wv2uc Рік тому

    It's not circle ,we cal it as ring

  • @harsharajendran41088
    @harsharajendran41088 3 роки тому

    Hi! great video and was very easy to learn. In case you have to find the polynomial coefficients where they are given as a, b and c then how would you do that? Can we define the values of a,b and c to fall under the certain limits say within -infinity to +infinity or say some random integer?, plug them into the step where the quadratic equation is required and then go ahead??

  • @christopher8116
    @christopher8116 5 років тому +6

    I see your a victim of the 50+ tabs in Chrome, hahaha.

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  5 років тому +1

      Haha yes 😂😂

    • @christopher8116
      @christopher8116 5 років тому

      @@JishaandAlessandrosworld I know, why bookmark when you can keep opening new tabs, then spend a few weeks going though all your tabs.

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  5 років тому +1

      Exactly!! With bookmark you tend to forget about it. This way there is a finite chance that you will come back to it at some point of time 😁

  • @cagatayaksu6549
    @cagatayaksu6549 4 роки тому

    What is the numbers in the coefficients with all that "e"? I am assuming it is a float. But could you explain how that would be interpreted as normal number if we want to give the explicit equation for the polynom?
    Thank you btw, really nice, easy to grasp video.

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  4 роки тому +1

      Thank you! Can you let me know the time in the video where the coefficient in your question comes? I will try to answer your doubt. This way I don't have to look up all the video.

    • @cagatayaksu6549
      @cagatayaksu6549 4 роки тому

      @@JishaandAlessandrosworld Thanks for the reply. I meant the coefficients at 6:51 for example. How do we interpret -1.6854...e-16 as a number? Or the coeffs. at 11:00 for that matter. It has been a while since I dealt with code but now I am trying to understand some data. It is probably a simple silly question. :D

    • @cagatayaksu6549
      @cagatayaksu6549 4 роки тому

      :(

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  4 роки тому

      Those numbers are zero. It has a finite value because of the machine precision. Are you confused by the syntax e-13?

    • @cagatayaksu6549
      @cagatayaksu6549 4 роки тому

      @@JishaandAlessandrosworld yeah exactly, so anything with an e is equal to zero?
      4.89e, 2.11e, 7.81e etc or do they have a value?

  • @pankajjoshi2547
    @pankajjoshi2547 4 роки тому

    thanku , how 1.6 ,2 and 5 came out can you explain manually in paper

  • @omkarsargar5375
    @omkarsargar5375 4 роки тому

    consider i have a data set and I say the first feature(Hours) is for X and the next Feature(test_result) is y. Now i use np.plyplot(x,y,1) i get some values, my question is how to decide the value is to be 1 or 2 or what. Secondly what do these values say, Because when you change the degree in plyplot output values also change.

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  4 роки тому

      Thank you for your question. However, what is "np.plyplot"?. I am not familiar with such a function. If you are talking about the function polyfit discussed in the video, then the 1 or 2 corresponds to the degree of the polynomial you are trying to fit. This has been discussed in detail in the video together with how you choose the degree for fitting.

    • @omkarsargar5375
      @omkarsargar5375 4 роки тому

      @@JishaandAlessandrosworld My apologies, it had to be np.polyfit, question is how to decide the order of polynomial is, I still could not get it, supposing the data i have is csv file.

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  4 роки тому +1

      Usually you have a theoretical model and you will want to fit the data to that. Most of the time you more or less know how your data might behave and then you check it by fitting it to polynomial or exponential or whatever function. If you think it is a polynomial function, you can try an arbitrary degree and check the values of the coefficients returned. Depending on how many coefficients are returned you can say that it is a linear, quadratic, third degree and so on and so forth. The last part of the video explains that, where we have a data which is linear and we tried to fit it with quadratic. The second order terms are negligible in this case.

    • @sophiafox5939
      @sophiafox5939 4 роки тому +1

      You can fit almost any data to any function. To know what is the 'correct' one however can be difficult particularly if you don't know what the relationship should be. Furthermore fitting data to an extremely high order polynomial for example can result in poor conditioning (you need more data points to make the fit). You can look at the sum of squares error between the fit and your data and additionally you can put boundaries on the initial guesses that the fit makes to estimate your parameters. These boundary conditions can be set based on common sense and often the initial values for guessing are the most important for an accurate fit (think of needle in a haystack)

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  4 роки тому +1

      Totally agree.

  • @jimmyloluolajide7777
    @jimmyloluolajide7777 4 роки тому

    Excellent tutorial!!! Please, is there a way to contact you guys via email? Thanks

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  4 роки тому

      Thank you! If you have some specific question about the video may be you could ask here and could be helpful to others as well. However, you can write to us at cpjisha.personal@gmail.com

  • @renanlarrieu
    @renanlarrieu 3 роки тому

    Does anyone have the code?

    • @JishaandAlessandrosworld
      @JishaandAlessandrosworld  3 роки тому +1

      you can find the jupyter notebook here. github.com/cpjisha/Sci-comp-python-files/blob/master/Polynomial_Fitting.ipynb

    • @renanlarrieu
      @renanlarrieu 3 роки тому

      @@JishaandAlessandrosworld thank u so much!!!