MATLAB: How to combine data of two different signals

MATLAB

In the below code, i have modulated the same signal twice and then multiplied with the d. But now i want to modulate 2 different signal and then multiplied with the d. I dont understand how to do that.
x = round(rand(1, 100));
M= 4;
Scheme = 'QAM';
L=2;
d=[2 1]; % distances
for i = 1 : L
Mod(:, :, i) = Modulate(x, M, Scheme);
end
M = zeros(nt, enc_length);
for i = 1 : L
M = M + d(i) * Mod(:, :, i);
end
% %% for different signal
x1= round(rand(1, 100));
x2= round(rand(1, 100));

Best Answer

x = round(rand(2, 100));
and
Mod(:,:,i) = Modulate(x(i,:), M, Scheme);
However, I do not find a function Modulate with a capital-M, only modulate with lower-case M.
Related Question