Or you could do it the expensive way and make actual spheres
clf
x = linspace(0,1,10);
y = x.^2;
% plot the lines
plot(x,y,'k'); hold on
% plot the markers
scale = 0.015;
[xx yy zz] = sphere(20);
xx = xx*scale;
yy = yy*scale;
zz = zz*scale;
for k = 1:numel(x)
surf(xx+x(k),yy+y(k),zz)
end
shading flat
colormap([1 1 1]*0.7)
lightangle(gca,-135,45)
lighting gouraud
material([0.3 1 1])
xlim([-0.01 1])
ylim([0 1.01])
You could also create any small image and place copies of it as markers. Note the use of transparency and the fact that the marker will appear upside-down.
clf
x = linspace(0,1,10);
y = x.^2;
% plot the lines
plot(x,y,'k'); hold on
% place actual marker images
[mk,~,alph] = imread('sphmarker.png'); % sphere
%[mk,~,alph] = imread('sphmarker2.png'); % smiley
markerrad = 0.015;
for k = 1:numel(x)
im = imagesc(x(k)+[-1 1]*markerrad,y(k)+[-1 1]*markerrad,mk);
im.AlphaData = alph;
end
You might also be able to look an the FEX and see if someone has a solution that would work.
No se puede completar la acción debido a los cambios realizados en la página. Vuelva a cargar la página para ver el estado actualizado.
Translated by
Seleccione un país/idioma
Seleccione un país/idioma para obtener contenido traducido, si está disponible, y ver eventos y ofertas de productos y servicios locales. Según su ubicación geográfica, recomendamos que seleccione: .
También puede seleccionar uno de estos países/idiomas:
Cómo obtener el mejor rendimiento
Seleccione China (en idioma chino o inglés) para obtener el mejor rendimiento. Los sitios web de otros países no están optimizados para ser accedidos desde su ubicación geográfica.