[MATLAB] Moving hyst plot data generator to its own function.
[MATLAB] Saving hystheresis data to mat file.