I would like to find fit functions for data, that has linear dependency first and changes to quadratic at some point.
The fit function should then be used to predict future values. Since I am new to pymc3, I looked into some examples and tried to use them for my problem. The concept of spline regression (https://ckrapu.github.io/2018/07/09/Spline-Regression.html) seemed promising. Here is the notebook with my approach: https://nbviewer.jupyter.org/github/violairis/Spline-Regression-with-pymc3/blob/master/Spline%20Regression%20using%20pymc3.ipynb
But the best result I was able to get looks like this:
Could you give me a hint, where I am doing wrong? I would also be happy to hear about alternative approaches to this kind of problem, in case the spline regression is not a good way to handle this. Any help is much apprechiated, thank you!