How do I plot a colored disk on a globe?

2 views (last 30 days)
Scott
Scott on 5 Aug 2013
I would like to plot a diskoid on the surface of a globe. The diskoid would colored to represent distance from the center.
ie green in the center fading to blue fading red at the edge and red everywhere outside the diskoid.
I would like to be able to both choose the radius on the diskoid and where the center point of the diskoid lies on the surface of the globe.
Here is what I have so far...not sure if I am on the right track or not.
baseLat = 53; baseLon = -60; %This is where i would like the diskoid centered
figure
axesm('globe','galt',0)
axesm ('globe','Grid', 'on');
camposm(baseLat,baseLon,1)
disk=zeros(180,360);
for i=1:180
for ii = 1:360
if (ii-300)^2+(i-143)^2>15^2
disk(i,ii)=20;
end
end
end
meshm(disk, [1 90 0])
load coast
plotm(lat, long)
axis off
set(gcf,'Color',[0 0 0]);
set(gca,'CameraViewAngle',70)
The diskoid is really distorted and if it goes over the north pole then all bets are completely off.
Thanks

Answers (0)

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!