The way to go here, in my opinion, is to use scatter3
, where you can specify the colour value explicitly:
scatter3(x,y,z,3,1:numel(x))
where 3
would be the size argument and 1:numel(x)
gives increasing colours. Afterward you can choose your colour map as usual.

Using plot3
you could do the same, but it requires a loop:
cMap = jet(numel(x)); % Generates colours on the desired map
figure
hold on % Force figure to stay open, rather than overwriting
for ii = 1:numel(x)
% Plot each point separately
plot3(x(ii), y(ii), z(ii), 'o', 'color',cMap(ii,:))
end

I'd only use the plot3
option in case you want successively coloured lines between elements, which scatter3
can't do:
cMap = jet(numel(x)); % Generates colours on the desired map
figure
hold on % Force figure to stay open, rather than overwriting
for ii = 1:numel(x)-1
% Plot each line element separately
plot3(x(ii:ii+1), y(ii:ii+1), z(ii:ii+1), 'o-', 'color',cMap(ii,:))
end
% Redraw the last point to give it a separate colour as well
plot3(x(ii+1), y(ii+1), z(ii+1), 'o', 'color',cMap(ii+1,:))

NB: tested and exported images on R2007b, cross-checked the syntax with R2021b docs