MATLAB Function Reference    

Low-Level File I/O

fclose Close one or more open files
feof Test for end-of-file
ferror Query MATLAB about errors in file input or output
fgetl Return next line of file as string without line terminator(s)
fgets Return next line of file as string with line terminator(s)
fopen Open file or obtain information about open files
fprintf Write formatted data to file
fread Read binary data from file
frewind Rewind open file
fscanf Read formatted data from file
fseek Set file position indicator
ftell Get file position indicator
fwrite Write binary data to file

  Opening, Loading, Saving Files Text Files