Weather Data: Difference between revisions
From Federal Burro of Information
Jump to navigationJump to search
(Created page with " == Canadian Data == https://drive.google.com/drive/folders/1WJCDEU34c60IfOnG4rv5EPZ4IhhW9vZH <pre> for year in `seq 1998 2008`; do for month in `seq 1 12`; do wget --c...") |
No edit summary |
||
Line 13: | Line 13: | ||
done; | done; | ||
done | done | ||
<pre> | </pre> | ||
WHERE; | WHERE; | ||
* year = change values in command line (`seq 1998 2008) | |||
* month = change values in command line (`seq 1 12) | |||
* format= [csv|xml]: the format output | |||
* timeframe = 1: for hourly data | |||
* timeframe = 2: for daily data | |||
* timeframe = 3 for monthly data | |||
* Day: the value of the "day" variable is not used and can be an arbitrary value | |||
* For another station, change the value of the variable stationID | |||
* For the data in XML format, change the value of the variable format to xml in the URL. |
Revision as of 13:50, 20 July 2020
Canadian Data
https://drive.google.com/drive/folders/1WJCDEU34c60IfOnG4rv5EPZ4IhhW9vZH
for year in `seq 1998 2008`; do for month in `seq 1 12`; do wget --content-disposition "https://climate.weather.gc.ca/climate_data/bulk_data_e.html?format=csv&stationID=1706&Year=${year}&Month=${month}&Day=14&timeframe=1&submit= Download+Data" ; done; done
WHERE;
- year = change values in command line (`seq 1998 2008)
- month = change values in command line (`seq 1 12)
- format= [csv|xml]: the format output
- timeframe = 1: for hourly data
- timeframe = 2: for daily data
- timeframe = 3 for monthly data
- Day: the value of the "day" variable is not used and can be an arbitrary value
- For another station, change the value of the variable stationID
- For the data in XML format, change the value of the variable format to xml in the URL.