Stability threshold approach for complex dynamical systems