A two-stage transfer learning code in MATLAB