|
> I wish I could get the code rewritten without nested functions that
> seem to inherit and pass on variables without properly included in
> the argument lists.
I think the introduction of nested functions to Matlab led to even
more unreadable code. They might be nice to have for a short
three-liner in another function. But excessively used like in the
current contest, they lead to perfect disorientation and mistakes.
You will have to be extremely attentive not to use a variable like i
or m or n that is also used in the parent function, if there are many
nested functions over a large number of lines.
|