
if PlotType==4
   % scatter plot
   axis([-pi/2 pi/2 0 4])
   dir = './1dref/';
   dim = 1;
   [amrdata1d,t1d] = readamrdata(dim,Frame,dir);
   if isempty(t1d)
      disp('Run xclaw in 1dref to generate 1d reference solution')
    else
      hold on;
      [q1d,x1d] = plotframe1ez(amrdata1d,mq,'r-');
      hold off;
    end
  legend('2d sphere results','1d reference solution','Location','North')
  xlabel('latitude s','fontsize',15)
  ylabel('fluid depth','fontsize',15)
  title(['t = ' num2str(t)],'FontSize',15)
  end


if PlotType~=4

colormap(1-.8*(0:.1:1)' * [1 1 0])  % shades of blue
caxis([.5 3])
%colorbar
%colormap([0.8 0.8 1.0])   
if Manifold==0
  daspect([1 1 1])
  axis([-3 1 -1 1])
  view(2)
  return
  end

%axis([-.8 .8 -.8 .8 -.8 .8])

caxis([.5 1.5])
daspect([1 1 1])
grid off
axis off
%title(['t = ' num2str(t)],'FontSize',15)
title(' ')


% plot some grid lines:
creatingclines=1;           % used in plotframe2.m 
hold on
% equator and two circles through poles:
[xeq,yeq,zeq] = mapc2m(-2*ones(1,100),linspace(-1,1,100));
plot3(xeq,yeq,zeq,'r')
[xeq,yeq,zeq] = mapc2m(-ones(1,100),linspace(-1,1,100));
plot3(xeq,yeq,zeq,'r')
[xeq,yeq,zeq] = mapc2m(zeros(1,100),linspace(-1,1,100));
plot3(xeq,yeq,zeq,'r')
[xeq,yeq,zeq] = mapc2m(ones(1,100),linspace(-1,1,100));
plot3(xeq,yeq,zeq,'r')
[xeq,yeq,zeq] = mapc2m(linspace(-3,1,100),ones(1,100));
plot3(xeq,yeq,zeq,'r')
[xeq,yeq,zeq] = mapc2m(linspace(-3,1,100),-ones(1,100));
plot3(xeq,yeq,zeq,'r')
[xeq,yeq,zeq] = mapc2m(linspace(-3,1,100),zeros(1,100));
plot3(xeq,yeq,zeq,'r')

creatingclines=0;

% plot the axis of rotation:
%plot3(xax,yax,zax,'b','LineWidth',2)

plot3([0 0],[0 0],[-1.5 1.5],'r','LineWidth',2)
text(-.1,0,1.4,'N')
text(-.1,0,-1.4,'S')
title(['top view at time t = ' num2str(t)])



%showgridlines
hold off

input('Hit return for bottom view ');
view([-60 -30])  % to view from below
title(['bottom view at time t = ' num2str(t)])

end
