Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- %totlu1
- %O7VX14
- meresiErtekek=randi([900,1090],4,3,31);
- resz1=squeeze(meresiErtekek(1,3,:));
- y=linspace(1,31,31);
- figure(1);
- plot(y,resz1, '-.ko','LineWidth', 3, 'MarkerSize', 11);
- h=find(resz1>=930&resz1<=1060);
- ertek=resz1(h);
- hold on;
- plot(h,ertek,'o', 'MarkerSize',15,'MarkerEdgeColor', 'red', 'MarkerFaceColor','green');
- hold off;
- title('elso szenzor, esti meres, mindennap','FontSize', 15);
- xlabel('napok szama', 'FontSize',13,'FontWeight','bold');
- ylabel('legkori nyomas [hPa] ', 'FontSize',13,'FontWeight','bold');
- xlim([1,31]);
- ylim([890,1100]);
- set(gca, 'FontSize', 15);
- xL=get(gca, 'XLim');
- line(xL,[930 930],'Color','m','LineWidth',2);
- line(xL,[1060 1060],'Color','m','LineWidth',2);
- k=resz1<=930 | resz1>=1060;
- resz1(k)=0;
- el=resz1(11:20);
- s=find(el>0);
- db=length(resz1(s));
- fprintf('Helyes meresi ertekek darabszama (elso szenzor, esti meres, 1120. napokra): %0.0f \n', db);
- d2=squeeze(meresiErtekek(2,2,:));
- d3=squeeze(meresiErtekek(3,2,:));
- d4=squeeze(meresiErtekek(4,2,:));
- d2l=find(d2>=930 & d2<=1060);
- d2h=d2(d2l);
- atl2=mean(d2h);
- d3l=find(d3>=930 & d3<=1060);
- d3h=d3(d3l);
- atl3=mean(d3h);
- d4l=find(d4>=930 & d4<=1060);
- d4h=d4(d4l);
- atl4=mean(d4h);
- fprintf('A deli atlaga az elso szenzornak: %+09.3f, a masodiknak: %+09.3f es a harmadiknak: %+09.3f \n',atl2,atl3,atl4);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement