How can I continue with a loop when an error occurs in MATLAB?

Viewed 16992

I'm converting some .dat files into .mat files using a function. I'm calling this function inside a loop to convert a number of files. There are some cases where my .dat file is corrupted and the function cannot convert and an error occurs, stopping the loop.

Now my question is: Is there any command wherein when the error occurs it should skip the current (i) value in the loop and go for the next increment value (in my case the next file)?

1 Answers
Related