% :::::::::::::::::::::::::: reading txt-data  :::::::::::::::::::::::::
clear all; close;
disp(['°°°°°°°°°°°° S T A R T °°°°°°°°°°°°°°°°°°°° ',date,' °°°°°°°°°°°°°°°°°°°°°'])
% :::::::::::::::::::::::::::::::::: TEST-Datei :  20160821.txt   ::::::::::::::::::..
fin = fopen('20160821.txt','r');                               % open ''input file'' for reading
fOut = fopen( [ 'new_' '20160821.txt'], 'w');             % open ''output file'' for writing
nextLine = fgets(fin);                                            % Get the first line of input
while nextLine >= 0                                               % Loop until getting -1 (end of file)
   nextLine = strrep(nextLine, 'T', '__');                 % Replace ''T'' with Blanks
   nextLine = strrep(nextLine, 'Z', '__');                 % Replace ''S'' with Blanks  
   fprintf(fOut, '%s', nextLine);                              % Write the line to the output file
   nextLine = fgets(fin);                                        % Get the next line of input
end
fclose(fin);                                                        % Close the input file
fclose(fOut);                                                     % Close the output file