Stepper processes are generally used to break down complex data entry forms into a more digestible format. It also means that the information being asked can be divvied up into clear categories or progression.
Because this choice is so heavily dependent on the context, a decisive research finding that could establish a pattern might be hard to come by. A non-linear stepper seems to be the obvious choice owing to it's flexibility, but there are a few standout factors to consider.
Is it possible that the user could create some un-intended side-effects for their data in the case of non-linear data input? For example, could a user enter data in step 4, that could impact data entry in step 2?
Are later steps dependent on earlier ones?
Sometimes, the data entered in earlier steps defines what needs to be asked in later steps. If that's the case, you might have to go for a linear stepper, as it's a system constraint that's probably unavoidable.
Are edits allowed for all steps?
If all steps are editable until the data is submitted, then you might have to consider side-effects and impacts anyway.
Can a user skip a step?
If a step is allowed to be skipped, that just means a section of your data is optional. In that case, is there a particular reason for the optional data to be asked at a particular step?
Can a user edit their data later?
Let's say the data was submitted, linear or non-linear. Now if you allow the user to go back and edit their data input, is restricting them to a linear stepper making sense? If it does, then you have a valid reason to stay linear.
Overall, a non-linear stepper would work in most situations, unless there's a valid reason, such as inter-step dependencies, essential progression or another system constraint.
However, if you land at a linear stepper, ask yourself whether you need a stepper at all? Because a pair of Back - Next buttons can do the job perfectly well too.