how to find out the coldest point

조회 수: 1 (최근 30일)
navya mudiraj
navya mudiraj 2014년 4월 23일
댓글: David Sanchez 2014년 4월 23일
clear all;fclose all;clc;close all;clear a=fopen('files.dat','r'); gg=0; while ~feof(a) fgets(a); gg=gg+1; end frewind(a) for i=1:gg b=fscanf(a,'%s',1); c=load(b); high(:,i)=c(:,1); pre(:,i)=c(:,2); temp(:,i)=c(:,3); rh(:,i)=c(:,4); u(:,i)=c(:,5); v(:,i)=c(:,6); ws(:,i)=c(:,7); wd(:,i)=c(:,8);
end
for i=1:400
t(i,:)=nanmean(temp(i,:));
pres(i,:)=nanmean(pre(i,:));
rhs(i,:)=nanmean(rh(i,:));
uw(i,:)=nanmean(u(i,:));
vw(i,:)=nanmean(v(i,:));
wsp(i,:)=nanmean(ws(i,:));
wdr(i,:)=nanmean(wd(i,:));
hight(i,:)=nanmean(high(i,:));
end
subplot(241);plot(t,high(100:200,:);title('temperature'),ylim([1,20]),
xlabel('temperature'),ylabel('hight'),legend('temperature'),grid on;
subplot(242);plot(pre,high);title('pressure'),ylim([1,20]), xlabel('pressure'),ylabel('hight'),grid on, legend('pressure');
subplot(243);plot(rhs,high);title('relative humidity'),ylim([1,20]), xlabel('relativehumidity'),ylabel('hight'),grid on,legend('relativehumidity');
subplot(244);plot(uw,high);title('u_zonal'),ylim([1,20]), xlabel('u_zonal'),ylabel('hight'),grid on, legend('u_zonal');
subplot(245);plot(vw,high);title('v-meriodanal'), xlabel('v_meriodanal'),ylabel('hight'),grid on,legend('v-meriodanal');
subplot(246);plot(wsp,high);title('wind speed'), xlabel('windspeed'),ylabel('hight'),grid on,legend('windspeed');
subplot(247);plot(wdr,high);title('wind direction'),ylim([1,20]), xlabel('winddirection'),ylabel('hight'),grid on, legend('winddirection'); for i=1:400 tdif(i,:)=t(i,:)-temp(i,:); pdif(i,:)=pres(i,:)-pre(i,:); rdif(i,:)=rhs(i,:)-rh(i,:); udif(i,:)=uw(i,:)-u(i,:); vdif(i,:)=vw(i,:)-v(i,:); wsdif(i,:)=wsp(i,:)-ws(i,:); wddif(i,:)=wdr(i,:)-wd(i,:); end
subplot(241);plot(tdif,high);title('temperature'),
xlabel('temperature'),ylabel('hight'),grid on, legend('temperature');
subplot(242);plot(pdif,high);title('pressure'), xlabel('pressure'),ylabel('hight'),grid on, legend('pressure');
subplot(243);plot(rdif,high);title('relative humidity'), xlabel('relativehumidity'),ylabel('hight'),grid on,legend('relativehumidity');
subplot(244);plot(udif,high);title('u_zonal'), xlabel('u_zonal'),ylabel('hight'),grid on, legend('u_zonal');
subplot(245);plot(vdif,high);title('v-meriodanal'), xlabel('v_meriodanal'),ylabel('hight'),grid on,legend('v-meriodanal');
subplot(246);plot(wsdif,high);title('wind speed'), xlabel('windspeed'),ylabel('hight'),grid on,legend('windspeed');
subplot(247);plot(wddif,high);title('wind direction'), xlabel('winddirection'),ylabel('hight'),grid on, legend('winddirection'); for i=1:400
t(i,:)=nanmean(temp(i,:)); pres(i,:)=nanmean(pre(i,:)); rhs(i,:)=nanmean(rh(i,:)); uw(i,:)=nanmean(u(i,:)); vw(i,:)=nanmean(v(i,:)); wsp(i,:)=nanmean(ws(i,:)); wdr(i,:)=nanmean(wd(i,:)); end
subplot(241);plot(tdif,high(100:200,:)
title('temperature'),ylim([1,20]),
xlabel('temperature'),ylabel('hight'),grid on, legend('temperature');
subplot(242);plot(pdif,high);title('pressure'),ylim([1,20]),
xlabel('pressure'),ylabel('hight'),grid on, legend('pressure');
subplot(243);plot(rdif,high);title('relative humidity'),ylim([1,20]), xlabel('relativehumidity'),ylabel('hight'),grid on,legend('relativehumidity');
subplot(244);plot(udif,high);title('u_zonal'),ylim([1,20]),
xlabel('u_zonal'),ylabel('hight'),grid on, legend('u_zonal');
subplot(245);plot(vdif,high);title('v-meriodanal'),ylim([1,20]), xlabel('v_meriodanal'),ylabel('hight'),grid on,legend('v-meriodanal','hight');
subplot(246);plot(wsdif,high);title('wind speed'),ylim([1,20]), xlabel('windspeed'),ylabel('hight'),grid on,legend('windspeed');
subplot(247);plot(wddif,high);title('wind direction'),ylim([1,20]), xlabel('winddirection'),ylabel('hight'),grid on, legend('winddirection');
hight =high(100:200,:);
temperature=temp(100:200,:);
pressure=pre(100:200,:);
relative =rh(100:200,:);
zonal=u(100:200,:);
meriodanal=v(100:200,:);
winds=ws(100:200,:);
windr=wd(100:200,:);
mtep=mean(temperature);
mhig=mean(hight);
subplot(241);plot(temperature,hight);title('temperature'),
xlabel('temperature'),ylabel('hight'),legend('temperature');
subplot(242);plot(pressure,hight);title('pressure'),
xlabel('pressure'),ylabel('hight'),legend('pressure');
subplot(243);plot(relative,hight);title('relative'),
xlabel('relative'),ylabel('hight'),legend('relative');
subplot(244);plot(zonal,hight);title('zonal'),
xlabel('zonal'),ylabel('hight'),legend('zonal');
subplot(245);plot(meriodanal,hight);title('meriodanal'),
xlabel('meriodanal'),ylabel('hight'),legend('meriodanal');
subplot(246);plot(winds,hight);title('wnd speed'),
xlabel('winds'),ylabel('hight'),legend('winds');
subplot(247);plot(windr,hight);title('winddirection'),
xlabel('windr'),ylabel('hight'),legend('windr');
  댓글 수: 1
David Sanchez
David Sanchez 2014년 4월 23일
Do you expect anyone to read your code? Please, edit it with "{}Code". What do you mean by the coldest point?

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Signal Analysis에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by