How to add highlighting of brused points on scatter3 in MATLAB

26 Views Asked by At

When I worked with the 2D chart, my points were marked with a red circle around

enter image description here

After i move to scatter3, and marking points here only changing color to red:

enter image description here

How to return the red circle around the point? It was very convenient

Filled do not works:

enter image description here

Code:

clearvars;
clc;
rng('default');
xsSplited=zeros(1000, 3);
ysSplited=zeros(1000, 3);
zsSplited=zeros(1000, 3);
for i=1:size(xsSplited, 2)
    xsSplited(:, i) = rand(1,1000);
    ysSplited(:, i) = rand(1,1000);
    zsSplited(:, i) = rand(1,1000);
end
distFig=figure(15);
hold on;
colorsOnGrapth={'b.', 'g.', 'k.'};
for i=1:size(xsSplited, 2)
    dalPlot=scatter3(xsSplited(:, i), ysSplited(:, i), zsSplited(:, i), string(colorsOnGrapth(i)));
end
hold off;
1

There are 1 best solutions below

3
Waleed Qaisrani On

use the filled argument.

scatter3(x,y,z,'filled')