%created for the matlab working group seminar #1: Excel to Matlab % % lry 6/30/06 ctd=[351.7 7.104 34.035 349.9 7.16 34.036 347.9 7.203 34.038 345 7.256 34.039 341.8 7.322 34.042 338.9 7.352 34.044 335.5 7.42 34.042 332.6 7.429 34.042 329.4 7.45 34.041 326 7.488 34.042 322.8 7.498 34.039 319.7 7.517 34.038 316.7 7.54 34.038 313.6 7.543 34.037 310.4 7.549 34.038 307.2 7.592 34.042 304 7.631 34.047 300.7 7.666 34.051 297.5 7.692 34.055 294.3 7.716 34.056 291.1 7.732 34.058 288 7.826 34.064 285 7.898 34.061 282 7.922 34.062 279 8.076 34.068 275.9 8.176 34.076 272.8 8.21 34.075 269.8 8.22 34.073 266.8 8.25 34.072 263.8 8.38 34.065 260.9 8.444 34.068 258 8.496 34.068]; %%define temperature: temp=ctd(:,2); %% pull out "bad" temps: ibad=find(temp>8); temp(ibad)=NaN; %% display mean temperature temp_mean=mean(temp) temp_nanmean=nanmean(temp) %% plot depth vs. temp plot(ctd(:,1),ctd(:,2),'.')