Added function for reading formationData from MATLAB