Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/salima station data #37

Merged
merged 3 commits into from
Sep 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions apps/picsa-tools/climate-tool/src/app/data/stations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,27 @@ export const STATIONS: IStationMeta[] = [
longitude: 35.4706477,
country: 'Malawi',
},
{
...db.meta({ _key: 'salima', _created }),
name: 'Salima',
latitude: -13.781570,
longitude: 34.456800,
country: 'Malawi',
},
{
...db.meta({ _key: 'kasungu', _created }),
name: 'Kasungu',
latitude: -13.036810,
longitude: 33.481230,
country: 'Malawi',
},
{
...db.meta({ _key: 'nkhotakota', _created }),
name: 'Nkhotakota',
latitude: -12.92842,
longitude: 34.283192,
country: 'Malawi',
},
{
...db.meta({ _key: 'chipata', _created }),
name: 'Chipata',
Expand Down
63 changes: 63 additions & 0 deletions apps/picsa-tools/climate-tool/src/assets/summaries/kasungu.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
Year,Rainfall,Start,End,Length
1960,458.6,,278,
1961,1024.1,160,285,125
1962,854.8,160,263,103
1963,767.4,124,257,133
1964,751,145,254,109
1965,667.4,158,296,138
1966,732.1,167,289,122
1967,618.2,157,295,138
1968,621.3,148,247,99
1969,666,166,268,102
1970,954.5,150,255,105
1971,430.3,148,268,120
1972,583.3,176,284,108
1973,856.4,175,302,127
1974,673,145,281,136
1975,725.7,193,298,105
1976,534.1,163,256,93
1977,880.5,184,279,95
1978,772.1,163,283,120
1979,1063.8,145,291,146
1980,1026.8,154,271,117
1981,714.4,180,291,111
1982,756.4,163,302,139
1983,720.8,165,272,107
1984,711.1,132,267,135
1985,1085.9,130,304,174
1986,793.1,118,253,135
1987,828.4,203,264,61
1988,914.5,181,276,95
1989,817.8,139,273,134
1990,781.6,149,282,133
1991,504.9,158,272,114
1992,794,165,272,107
1993,725.8,187,292,105
1994,501,187,284,97
1995,940.8,163,258,95
1996,838.4,165,283,118
1997,882.1,141,281,140
1998,837.8,178,272,94
1999,537.5,186,252,66
2000,791.3,165,266,101
2001,596.8,202,284,82
2002,1046.2,164,276,112
2003,812.9,154,280,126
2004,879.9,149,259,110
2005,550.7,150,280,130
2006,1149.3,139,243,104
2007,576.1,174,253,79
2008,645.7,150,278,128
2009,785.8,165,275,110
2010,545.6,159,282,123
2011,860.7,185,276,91
2012,596.4,165,262,97
2013,728.3,180,243,63
2014,725,177,283,106
2015,610.9,161,266,105
2016,851.6,197,279,82
2017,710.4,150,286,136
2018,660.5,165,285,120
2019,762.1,164,248,84
2020,620.1,163,260,97
2021,25.8,,173,
64 changes: 64 additions & 0 deletions apps/picsa-tools/climate-tool/src/assets/summaries/nkhotakota.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
Year,Start,Length,Rainfall,End
1959,,,965.7,300
1960,167,131,1672.7,298
1961,138,162,1952.7,300
1962,150,145,1661.5,295
1963,124,158,1489.6,282
1964,171,131,1756.7,302
1965,171,95,1314.2,266
1966,163,139,1461.1,302
1967,120,179,1361.3,299
1968,151,148,1646,299
1969,164,135,1344.9,299
1970,149,148,1793,297
1971,170,128,1945,298
1972,153,149,1770.3,302
1973,168,134,1840.4,302
1974,158,145,1380.2,303
1975,157,141,2239.7,298
1976,163,136,1346.7,299
1977,147,151,2247,298
1978,156,139,2001.6,295
1979,142,151,1663.7,293
1980,156,144,1753.2,300
1981,152,144,1857.9,296
1982,140,162,1144.9,302
1983,165,110,971.8,275
1984,132,152,1574.6,284
1985,139,164,2123,303
1986,161,131,1216.7,292
1987,166,137,1217.1,303
1988,171,130,1690.4,301
1989,153,143,1472.9,296
1990,164,118,1185,282
1991,209,90,1017.4,299
1992,168,137,1334.4,305
1993,168,116,959.2,284
1994,148,137,1079.7,285
1995,161,121,1199.2,282
1996,168,124,989.2,292
1997,154,135,1584.9,289
1998,187,116,1226,303
1999,165,135,883.8,300
2000,154,127,1461.2,281
2001,158,131,1432.9,289
2002,163,116,1214.4,279
2003,153,151,1328.2,304
2004,151,145,1301.5,296
2005,182,118,1374.3,300
2006,164,135,1309.5,299
2007,154,144,1498.8,298
2008,149,130,1901.9,279
2009,165,135,1437.8,300
2010,153,131,1335.2,284
2011,164,113,1450.5,277
2012,163,116,1323.2,279
2013,146,157,1519.3,303
2014,172,119,1065,291
2015,163,117,815.7,280
2016,159,146,1200.6,305
2017,142,153,1548.7,295
2018,142,146,1487.5,288
2019,149,146,1550.1,295
2020,155,113,,268
2021,,,,
65 changes: 65 additions & 0 deletions apps/picsa-tools/climate-tool/src/assets/summaries/salima.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
Year,Rainfall,Start,End,Length
1959,729.7,,264,
1960,1454.8564,,298,
1961,1404.366,155,295,140
1962,1284.986,152,284,132
1963,1180.592,128,268,140
1964,1153.922,172,274,102
1965,788.67,173,272,99
1966,809.752,165,297,132
1967,1145.032,145,289,144
1968,1308.608,171,288,117
1969,1114.298,156,289,133
1970,1578.12,150,282,132
1971,1284.732,132,301,169
1972,908.05,171,287,116
1973,1603.502,159,301,142
1974,902.98,159,278,119
1975,1888.998,158,295,137
1976,982.98,164,283,119
1977,2361.946,149,298,149
1978,1284.732,160,289,129
1979,1342.136,140,291,151
1980,1236.7,172,271,99
1981,781.4,174,295,121
1982,1089.9,154,281,127
1983,743.1,167,275,108
1984,1066.7,162,277,115
1985,1469.6,157,288,131
1986,1039.9,155,277,122
1987,1722.6,158,303,145
1988,1685.5,158,275,117
1989,1054.6,153,282,129
1990,1043.2,184,263,79
1991,1029.4,135,296,161
1992,1392.7,163,304,141
1993,844.7,188,258,70
1994,451.7,183,266,83
1995,1027.9,176,297,121
1996,1227.6,171,282,111
1997,1685.5,147,282,135
1998,1164.5,148,268,120
1999,763.44,194,292,98
2000,1684,122,272,150
2001,1559.9,175,291,116
2002,1618.8,165,278,113
2003,1050.17,169,293,124
2004,895.1,148,301,153
2005,1671,165,280,115
2006,1366.4,148,291,143
2007,1265.7,160,283,123
2008,1236.6,140,276,136
2009,1225.5,183,299,116
2010,1052.6,158,264,106
2011,1116.2,184,286,102
2012,718.6,141,254,113
2013,985.4,166,302,136
2014,699.8,174,275,101
2015,572.7,171,278,107
2016,1299.8,159,286,127
2017,1119.5,150,288,138
2018,1093.9,159,285,126
2019,1028.9,149,269,120
2020,926.1,156,278,122
2021,1465.5,172,287,115
2022,0,,,
12 changes: 12 additions & 0 deletions documentation/developers/climate-tool/adding-station.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Adding Station

0. Ensure the data is processed in a format to match the app data.
See examples in `apps\picsa-tools\climate-tool\src\assets\summaries`

1. Create an entry for station in the file
`apps\picsa-tools\climate-tool\src\app\data\stations.ts`

Use https://www.latlong.net/ to pick gps coordinates

2. Populate a csv file matching the station id in
`apps\picsa-tools\climate-tool\src\assets\summaries`