function plotdata(info,dirs)

% settings
switch info.run
    case 'blankenberge'
        us = 'u_mean';
        vs = 'v_mean';
        cl = [0 1];
        fname = 'tide1_cos_7days_NAP.txt';
    otherwise
        us = 'u';
        vs = 'v';
        cl = [0 .5];
        fname = 'Tide_xbeach_130207_00h00.txt';
end

% read measurements
m    = load(fname);
tm   = m(:,1)/3600;
m1   = m(:,2);
m2   = m(:,3);

% read output
d    = xb_read_dims; d.t = d.t/3600;
xbo1 = xs_peel(xb_read_output(pwd,'vars','zs','stride',[1 d.ny 1],'length',[-1 -1 1]));

% create plot
figure;
set(gcf,'color','w')

% plot timeseries
subplot(3,3,7:8); hold on;
plot(d.t,squeeze(xbo1.zs(:,1,1))','or','DisplayName', 'XB x1' );
plot(d.t,squeeze(xbo1.zs(:,end,1))','ob','DisplayName', 'XB x2');
plot(tm,m1,'-r','DisplayName', 'OBS x1' );
plot(tm,m2,'-b','DisplayName', 'Obs x2' );
axis([min(tm) max(d.t) min(m1) max(m2)])
xlabel('time [hr]');
ylabel('zs [m]');
box on;

s = [];
for i = 1:6
    %it=49+8*(i-1);
    %it=13+4*(i-1);
    it = i;

    xbo2 = xs_peel(xb_read_output(pwd,'vars',{us vs},'start',it-1,'length',1));

    u = squeeze(xbo2.(us));
    v = squeeze(xbo2.(vs));

    s = [s subplot(3,3,i)];
    pcolor(d.x,d.y,sqrt(u.^2+v.^2)); shading interp; colormap jet; hold on; grid on
    q = quiver(d.x(1:2:end,1:5:end),d.y(1:2:end,1:5:end),u(1:2:end,1:5:end)*500,v(1:2:end,1:5:end)*500,0,'color',[0 0 0]);
    hcb = colorbar;colorTitleHandle = get(hcb,'Title'); set(colorTitleHandle ,'String','u [m/s]');
    %colquiver(get(q,'Children'),sqrt(u.^2+v.^2)); colquiver does not work
    axis equal;
    title(['t = ',num2str(d.t(it)),'hr'])

    if i<4
        set(gca,'xtick',[])
    end
    if mod(i,3)~=1
        set(gca,'ytick',[])
    end
    if mod(i,3)==1
        ylabel('y [m]')
    end
    if i>3
        xlabel('x [m]')
    end

    subplot(3,3,7:8);
    yl = get(gca,'YLim');
    plot([d.t(it) d.t(it)],yl,'k','HandleVisibility','off');
end
subplot(3,3,7:8);
legend('Location','eastoutside')
s = [s subplot(3,3,9)];
set(s,'CLim',cl);
%colorbar;
set(gca,'visible','off');

xb_write_plot(gcf,dirs.output,'tide');