Guest User

Untitled

a guest
Apr 28th, 2012
2
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.62 KB | None | 0 0
  1. function weatherplot()
  2. %%%%%%%%%%%%%%%%%%%%%%
  3. %Benjamin Buxton
  4. %Date:: 28/04/12
  5. %Input::None
  6. %Output:: Screen (+graph)
  7. %This program loads weather data as an ascii text file in a specific format of a specific directory and plots average wind speed and average gust speed against days for a period
  8. %%%%%%%%%%%%%%%%%%%%%%
  9.  
  10. weatherDat=load('C:\Users\Ben\Documents\School\2012\SciComputing\Ex6\PerthWeatherDataApril08.txt');
  11.  
  12. numRows=size(weatherDat,1);
  13. dayNum=weatherDat(1:1:numRows, 1);
  14. avWindSpeed=weatherDat(1:1:numRows,4);
  15. gustSpeed=weatherDat(1:1:numRows,5);
  16.  
  17. plot(dayNum, avWindSpeed)
  18. hold on
  19. plot(dayNum, gustSpeed)
Advertisement
Add Comment
Please, Sign In to add comment