MATLAB: How to convert arrayfun to for loop

MATLAB

I found a source code online for a vigenere cipher and was wondering how to convert it to a for loop.
function Array = Operator
count = 27; %Primary function of the vignere encryptions by creating a 27x27 array
Length = 1:count; %array of length 27
% ie, Create a matrix with 27 shifted substitution alphabets
% 1 2 3 4 5 ... 26 27
% 2 3 4 5 6 ... 27 1
% 3 4 5 6 7 ... 1 2
% etc.
Array = arrayfun(@(n) circshift(Length, [0, -n]), 0:count-1, ...
'UniformOutput', false);
Array = reshape([Array{:}], count, count);
end
function cipher_text = vigenere_cipher(origionalText,key)
Array = Operator;
key = lower(key) - double('a') + 1; %Converts all text to lowercase
key(key < 0) = 27;
origionalText = lower(origionalText) - double('a') + 1;
origionalText(origionalText < 0) = 27;
keyLength = rem(0:(numel(origionalText)-1), numel(key))+1; %Converst the key to the length of the origional text
k = key(keyLength);
% Encrypt: C(n) = V(k(n), plaintext(n))
cipher_text = arrayfun(@(m,n) Array(m,n), k, origionalText) - 1;
cipher_text(cipher_text == 26) = double(' ') - double('a');
cipher_text = upper(char(cipher_text + double('a')));
end

Best Answer

count = 27;
Length = 1:count;
for n = 0:count-1
Array(n+1,:) = circshift(Length, [0, -n]);
end