Dear Statalist. I was wondering how to know what intial value to enter when doing a piecewise regression? After a lot of testing i find that the c value that minimise the MSE is 28. However, this required a lot of effort. When entering a low value for example 5 I get a relativly high MS value, the MS value jumps up an down until I tested a c value of 28 which gave the optimal result. When I put a c value of more than 28 the MS increases again. Any suggestion on how to find the optimal value that minimse the MS more effectivly?
My command is: nl (KOSTBHG = SIZE*{b1} + (SIZE>{c})*( SIZE-{c})*{b2}), variables(SIZE) initial(b1 0 c 28 b2 0) noconstant
My command is: nl (KOSTBHG = SIZE*{b1} + (SIZE>{c})*( SIZE-{c})*{b2}), variables(SIZE) initial(b1 0 c 28 b2 0) noconstant
Comment