Added simple Matlab functionality