I have a problem with approximating ROC for numerical algorithms for solving ODE's. It's known, that the global error for Euler's method is of order $O(h)$, and for 4th order Runge Kutta it's $O(h^4)$. Using linear regression for log-log correspondence between error and the step size however returns a variety of results for different equations (e.g. pendulum eq or trivial $y'=y$).
Is it a mistake to expect exact (sort of) analytical results for various problems? Should I pick large points for error evaluation instead of choosing e.g. $t = 10$? Or maybe I'm using the wrong formula? I've chosen the one from wikipedia - the $p$ in discretization methods https://en.wikipedia.org/wiki/Rate_of_convergence.