% :::::::::: Szenario - Matrix  mit Strings :::::::::::::::::::::
% .........................................................................
clear ; close all ; 
format compact
disp(['******* S T A R T ********* ',date,' **********'])
fprintf('\n')
fprintf( '\t   S z e n a r i o -  M a t r i x ');
fprintf(1,'\n')   
F = {'::::','===','===','===','===','::::' } ;
for i = 1 : length(F)
	fprintf(1,'\t %1s', F{i});
    %pause(0.2)
end
% ::::::::::::::::::::::::::: Szenario - Matrix ::::::::::::::::::::::::::::::
A = [15,1,3,5]/100;                             % > Ausfallwahrscheinlichkeiten %
a = zeros(size(A));

for n=1:length(A)
    b = a;
    b(:,n) = 1;
    a = [a;b];
end
count_a = sum(a,2);                              % > Zeilen - Summe, Zähler
d = [count_a, a];
D = sortrows(d);
SzM = D(:,2:end)     
pause(1)
% ::::::::::::::::: for Strings :::::::::::::::::::

 cList = {'Liss';  'Rio' ; 'Toki';  'Berl'; 'Kaps' };

% ::::::::::::::: How can I convert 1x3 cell array A = {'ab' 'cd' 'ef'} to string ? 
as1= char(cList)                               % note: a char mat 
as2= cat(2,cList{:})                           % note: no spaces between cells 
as3= sprintf('%s ', cList{:})                % the most versatile 
% as3(end)=''
pause(1)

cList = cList([ 1 2 3 4 5  ]) ;


% ::::::::::::::::::  TEST - Grafik >> formatting XTicklabels ::::::::::::::::::::::::::::::.
pause(1)
 monthlim=[1,31,59,90,120];                 % Xticks.
 xticklabels=['J';'F';'M';'A';'M'];                      %  XtickLabels.

 y=rand(1,365);
 plot([1:365],y)
set(gca,'Xlim',[1,120],'XTick',monthlim,'XTicklabel', cList)



% :::::::::::::Folgend:   Gedanke - Stütze ::::::::::::::::::::::::
% :::::::::::::::::::::::::.How can I convert each of my cells to a string ?
C = {'a', 9, 'b', 10}; 
numIndex = cellfun('isclass', C, 'double'); 
tmpStr = sprintf('%g;', C{numIndex}); 
C(numIndex) = dataread('string', tmpStr, '%s', 'delimiter', ';')