diff --git a/apps/picsa-apps/dashboard/src/app/app.component.scss b/apps/picsa-apps/dashboard/src/app/app.component.scss index 3c1834234..0194f6bcd 100644 --- a/apps/picsa-apps/dashboard/src/app/app.component.scss +++ b/apps/picsa-apps/dashboard/src/app/app.component.scss @@ -1,3 +1,8 @@ +:host { + // force page padding which normally only applies to tailwind breakpoints + --page-padding: 16px; +} + mat-sidenav { width: 256px; } diff --git a/apps/picsa-apps/dashboard/src/app/modules/climate/climate-api.mapping.ts b/apps/picsa-apps/dashboard/src/app/modules/climate/climate-api.mapping.ts index cfeb67da9..db88bb339 100644 --- a/apps/picsa-apps/dashboard/src/app/modules/climate/climate-api.mapping.ts +++ b/apps/picsa-apps/dashboard/src/app/modules/climate/climate-api.mapping.ts @@ -50,7 +50,11 @@ export const ApiMapping = ( }, }); if (error) throw error; - console.log('summary data', data); + // HACK - API issue returning huge data for some stations + if (data.data.length > 1000) { + console.error({ country_code, station_id, station_name, total_rows: data.data.length }); + throw new Error(`[rainfallSummary] Too many rows | ${station_name} ${data.data.length}`); + } // TODO - gen types and handle mapping const entry: IClimateProductInsert = { data: data as any, @@ -90,48 +94,49 @@ export const ApiMapping = ( }, // forecasts: async (country_code: IAPICountryCode) => { - const { data, error } = await api - .getObservableClient(`forecasts/${country_code}`) - .GET(`/v1/forecasts/{country_code}`, { params: { path: { country_code } } }); - if (error) throw error; - const forecasts = data.map((d): IForecastInsert => { - const { date, filename, format, type } = d; - // TODO - handle format - return { date_modified: date, filename, country_code, type, id: filename.split('/').pop() as string }; - }); - const { error: dbError, data: dbData } = await db - .table('climate_forecasts') - .upsert(forecasts) - .select<'*', IForecastRow>('*'); - if (dbError) throw dbError; - return dbData || []; + // const { data, error } = await api + // .getObservableClient(`forecasts/${country_code}`) + // .GET(`/v1/forecasts/{country_code}`, { params: { path: { country_code } } }); + // if (error) throw error; + // const forecasts = data.map((d): IForecastInsert => { + // const { date, filename, format, type } = d; + // // TODO - handle format + // return { date_modified: date, filename, country_code, type, id: filename.split('/').pop() as string }; + // }); + // const { error: dbError, data: dbData } = await db + // .table('climate_forecasts') + // .upsert(forecasts) + // .select<'*', IForecastRow>('*'); + // if (dbError) throw dbError; + // return dbData || []; + return []; }, forecast_file: async (row: IForecastRow) => { - const { country_code, filename } = row; - const { data, error } = await api.getObservableClient(`forecasts/${filename}`).GET(`/v1/forecasts/{file_name}`, { - params: { path: { file_name: filename } }, - parseAs: 'blob', - }); - if (error) throw error; - // setup metadata - const fileBlob = data as Blob; - const bucketId = country_code as string; - const folderPath = 'climate/forecasts'; - // upload to storage - await storage.putFile({ bucketId, fileBlob, filename, folderPath }); - // TODO - handle error if filename already exists - const storageEntry = await storage.getFileAlt({ bucketId, filename, folderPath }); - if (storageEntry) { - const { error: dbError } = await db - .table('climate_forecasts') - .upsert({ ...row, storage_file: storageEntry.id }) - .select('*'); - if (dbError) { - throw dbError; - } - return; - } - throw new Error('Storage file not found'); + // const { country_code, filename } = row; + // const { data, error } = await api.getObservableClient(`forecasts/${filename}`).GET(`/v1/forecasts/{file_name}`, { + // params: { path: { file_name: filename } }, + // parseAs: 'blob', + // }); + // if (error) throw error; + // // setup metadata + // const fileBlob = data as Blob; + // const bucketId = country_code as string; + // const folderPath = 'climate/forecasts'; + // // upload to storage + // await storage.putFile({ bucketId, fileBlob, filename, folderPath }); + // // TODO - handle error if filename already exists + // const storageEntry = await storage.getFileAlt({ bucketId, filename, folderPath }); + // if (storageEntry) { + // const { error: dbError } = await db + // .table('climate_forecasts') + // .upsert({ ...row, storage_file: storageEntry.id }) + // .select('*'); + // if (dbError) { + // throw dbError; + // } + // return; + // } + // throw new Error('Storage file not found'); }, }; }; diff --git a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/components/rainfall-summary/rainfall-summary.ts b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/components/rainfall-summary/rainfall-summary.ts index a804f8735..e79881efd 100644 --- a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/components/rainfall-summary/rainfall-summary.ts +++ b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/components/rainfall-summary/rainfall-summary.ts @@ -1,5 +1,5 @@ import { JsonPipe } from '@angular/common'; -import { AfterViewInit, ChangeDetectionStrategy, ChangeDetectorRef, Component } from '@angular/core'; +import { ChangeDetectionStrategy, ChangeDetectorRef, Component, effect } from '@angular/core'; import { MatButtonModule } from '@angular/material/button'; import { MatIconModule } from '@angular/material/icon'; import { MatTabsModule } from '@angular/material/tabs'; @@ -13,7 +13,7 @@ import { ChartConfiguration } from 'c3'; import { ClimateService } from '../../../../climate.service'; import { DashboardClimateApiStatusComponent, IApiStatusOptions } from '../../../../components/api-status/api-status'; -import { APITypes, IClimateProductRow } from '../../../../types'; +import { APITypes, IClimateProductRow, IStationRow } from '../../../../types'; type AnnualRainfallSummariesdata = APITypes.components['schemas']['AnnualRainfallSummariesdata']; @@ -39,13 +39,20 @@ interface IRainfallSummary { styleUrl: './rainfall-summary.scss', changeDetection: ChangeDetectionStrategy.OnPush, }) -export class RainfallSummaryComponent implements AfterViewInit { +export class RainfallSummaryComponent { public summaryMetadata: IRainfallSummary['metadata'] = {}; public summaryData: IRainfallSummary['data'] = []; public apiClientId: string; public chartDefintions: IChartMeta[] = []; public activeChartConfig: Partial; - constructor(private service: ClimateService, private cdr: ChangeDetectorRef, private supabase: SupabaseService) {} + constructor(private service: ClimateService, private cdr: ChangeDetectorRef, private supabase: SupabaseService) { + effect(() => { + const activeStation = this.service.activeStation(); + if (activeStation) { + this.loadActiveStation(activeStation); + } + }); + } public tableOptions: IDataTableOptions = { paginatorSizes: [25, 50], @@ -56,17 +63,20 @@ export class RainfallSummaryComponent implements AfterViewInit { showStatusCode: true, }; + private get activeStation() { + return this.service.activeStation(); + } + private get db() { return this.supabase.db.table('climate_products'); } - async ngAfterViewInit() { - const { activeStation } = this.service; + private async loadActiveStation(station: IStationRow) { // Load data stored in supabase db if available. Otherwise load from api // TODO - nicer if could include db lookups as part of mapping doc const { data, error } = await this.db .select<'*', IClimateProductRow>('*') - .eq('station_id', activeStation().id) + .eq('station_id', station.id) .eq('type', 'rainfallSummary') .single(); if (data) { @@ -79,9 +89,9 @@ export class RainfallSummaryComponent implements AfterViewInit { } public async refreshData() { - if (this.service.activeStation) { - this.apiClientId = `rainfallSummary_${this.service.activeStation().id}`; - const data = await this.service.loadFromAPI.rainfallSummaries(this.service.activeStation()); + if (this.activeStation) { + this.apiClientId = `rainfallSummary_${this.activeStation.id}`; + const data = await this.service.loadFromAPI.rainfallSummaries(this.activeStation); const summary = data?.[0]; if (summary) { this.loadData(summary.data as any); @@ -98,11 +108,12 @@ export class RainfallSummaryComponent implements AfterViewInit { private loadData(summary: IRainfallSummary) { console.log('load data', summary); - this.tableOptions.exportFilename = `${this.service.activeStation().station_name}_rainfallSummary.csv`; + this.tableOptions.exportFilename = `${this.activeStation.id}.csv`; const { data, metadata } = summary; this.summaryData = this.convertAPIDataToLegacyFormat(data); + // this.summaryData = data; this.summaryMetadata = metadata; - const { country_code } = this.service.activeStation(); + const { country_code } = this.activeStation; const definitions = CLIMATE_CHART_DEFINTIONS[country_code] || CLIMATE_CHART_DEFINTIONS.default; this.chartDefintions = Object.values(definitions); } @@ -114,10 +125,12 @@ export class RainfallSummaryComponent implements AfterViewInit { // HACK - use either end_rains or end_season depending on which has data populated // TODO - push for single value to be populated at api level End: el.end_rains_doy || el.end_season_doy, - Extreme_events: null as any, + // HACK - extreme events not currently supported + // Extreme_events: null as any, Length: el.season_length, // HACK - replace 0mm with null value - Rainfall: el.annual_rain || undefined, + // HACK - newer api returning seasonal_rain instead of annual_rain + Rainfall: el.seasonal_rain || undefined, Start: el.start_rains_doy, })); return data; diff --git a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/station-details.component.html b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/station-details.component.html index 437e5e86b..89e5044a2 100644 --- a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/station-details.component.html +++ b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/station-details.component.html @@ -1,13 +1,13 @@
- @if(station){ + @if(station(); as station){

{{ station.station_name }}

- +
- @for(key of stationSummary.keys; track $index){ + @for(key of stationSummary().keys; track $index){ } - @for(value of stationSummary.values; track $index){ + @for(value of stationSummary().values; track $index){ }
{{ key }}
{{ value }}
diff --git a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/station-details.component.ts b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/station-details.component.ts index b26f1c8f3..abe39ae92 100644 --- a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/station-details.component.ts +++ b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station-details/station-details.component.ts @@ -1,5 +1,5 @@ import { CommonModule } from '@angular/common'; -import { Component, OnInit } from '@angular/core'; +import { Component, computed } from '@angular/core'; import { MatProgressBarModule } from '@angular/material/progress-bar'; import { ClimateService } from '../../climate.service'; @@ -12,22 +12,17 @@ import { RainfallSummaryComponent } from './components/rainfall-summary/rainfall templateUrl: './station-details.component.html', styleUrls: ['./station-details.component.scss'], }) -export class StationDetailsPageComponent implements OnInit { - public get station() { - return this.service.activeStation(); - } +export class StationDetailsPageComponent { + public station = this.service.activeStation; - public get stationSummary() { - const entries = Object.entries(this.station || {}).filter(([key]) => !['id', 'country_code'].includes(key)); + stationSummary = computed(() => { + const station = this.service.activeStation(); + const entries = Object.entries(station || {}).filter(([key]) => !['id', 'country_code'].includes(key)); return { keys: entries.map(([key]) => key), values: entries.map(([, value]) => value), }; - } + }); constructor(private service: ClimateService) {} - - async ngOnInit() { - await this.service.ready(); - } } diff --git a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.html b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.html index 689a65faf..a52c0fd2e 100644 --- a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.html +++ b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.html @@ -1,35 +1,15 @@
-
-

Climate Data

- -
-

Stations ({{ service.apiCountryCode }})

-
-
- - - - - - - - - - - - - -
{{ i + 1 }}station_name{{ station.station_name }}
+ +
+
+ +
+
+
-
diff --git a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.scss b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.scss index bfe89e0d1..71b716694 100644 --- a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.scss +++ b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.scss @@ -12,3 +12,12 @@ tr.station-row { th { font-weight: bold; } + +dashboard-climate-api-status { + position: absolute; + top: 8px; + right: 8px; + background: rgba(255, 255, 255, 0.95); + border: 2px solid black; + z-index: 2; +} diff --git a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.ts b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.ts index acb369487..8e0273694 100644 --- a/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.ts +++ b/apps/picsa-apps/dashboard/src/app/modules/climate/pages/station/station.component.ts @@ -1,30 +1,42 @@ import { CommonModule } from '@angular/common'; -import { Component, computed, OnInit } from '@angular/core'; +import { Component, computed } from '@angular/core'; import { MatProgressSpinnerModule } from '@angular/material/progress-spinner'; -import { MatTableModule } from '@angular/material/table'; import { ActivatedRoute, Router, RouterModule } from '@angular/router'; +import { IDataTableOptions, PicsaDataTableComponent } from '@picsa/shared/features'; import { IMapMarker, PicsaMapComponent } from '@picsa/shared/features/map/map'; import { ClimateService } from '../../climate.service'; import { DashboardClimateApiStatusComponent, IApiStatusOptions } from '../../components/api-status/api-status'; import { IStationRow } from '../../types'; +const displayColumns: (keyof IStationRow)[] = ['district', 'station_name']; + @Component({ selector: 'dashboard-climate-station-page', standalone: true, imports: [ CommonModule, DashboardClimateApiStatusComponent, - MatTableModule, RouterModule, + PicsaDataTableComponent, PicsaMapComponent, MatProgressSpinnerModule, ], templateUrl: './station.component.html', styleUrls: ['./station.component.scss'], }) -export class ClimateStationPageComponent implements OnInit { - public displayedColumns: (keyof IStationRow)[] = ['station_id', 'station_name']; +export class ClimateStationPageComponent { + public tableOptions: IDataTableOptions = { + displayColumns: ['map', ...displayColumns], + sort: { id: 'district', start: 'desc' }, + handleRowClick: (station: IStationRow) => this.goToStation(station), + }; + public tableData = computed(() => { + const stations = this.service.stations(); + return stations.map((station, index) => { + return { ...station, map: index + 1 }; + }); + }); public mapMarkers = computed(() => { const stations = this.service.stations(); @@ -38,13 +50,13 @@ export class ClimateStationPageComponent implements OnInit { constructor(public service: ClimateService, private router: Router, private route: ActivatedRoute) {} - async ngOnInit() { - await this.service.ready(); - } - public handleMarkerClick(marker: IMapMarker) { const { _index } = marker; const station = this.service.stations()[_index]; + this.goToStation(station); + } + + private goToStation(station: IStationRow) { this.router.navigate(['./', station.station_id], { relativeTo: this.route }); } diff --git a/apps/picsa-apps/dashboard/src/app/modules/climate/types/api.d.ts b/apps/picsa-apps/dashboard/src/app/modules/climate/types/api.d.ts index b5e85f27f..2954d66e6 100644 --- a/apps/picsa-apps/dashboard/src/app/modules/climate/types/api.d.ts +++ b/apps/picsa-apps/dashboard/src/app/modules/climate/types/api.d.ts @@ -44,19 +44,9 @@ export interface paths { /** Read Stations */ get: operations["read_stations_v1_station__country___station_id__get"]; }; - "/v1/forecasts/{country_code}": { - /** - * List Forecasts - * @description Get latest forecasts for country - */ - get: operations["list_forecasts_v1_forecasts__country_code__get"]; - }; - "/v1/forecasts/{file_name}": { - /** - * Get Forecast - * @description Get forecast file - */ - get: operations["get_forecast_v1_forecasts__file_name__get"]; + "/v1/documents/{country}": { + /** Get Documents */ + get: operations["get_documents_v1_documents__country__get"]; }; } @@ -98,13 +88,13 @@ export interface components { AnnualRainfallSummariesParameters: { /** * Country - * @default zm_workshops + * @default mw_test * @enum {string} */ country?: "zm" | "mw" | "zm_test" | "mw_test" | "zm_workshops" | "mw_workshops"; /** * Station Id - * @default zambia_eastern + * @default Kasungu */ station_id?: string; /** @@ -143,20 +133,28 @@ export interface components { n_rain?: number; /** Start Rains Doy */ start_rains_doy?: number; - /** End Season Doy */ - end_season_doy?: number; - /** Season Length */ - season_length?: number; /** Start Rains Date */ start_rains_date?: unknown; + /** Start Rains Status */ + start_rains_status?: boolean; /** End Rains Doy */ end_rains_doy?: number; /** End Rains Date */ end_rains_date?: unknown; - /** End Season Date */ - end_season_date?: unknown; + /** End Rains Status */ + end_rains_status?: boolean; + /** Seasonal Rain */ + seasonal_rain?: number; /** N Seasonal Rain */ n_seasonal_rain?: number; + /** Season Length */ + season_length?: number; + /** End Season Doy */ + end_season_doy?: number; + /** End Season Date */ + end_season_date?: unknown; + /** End Season Status */ + end_season_status?: boolean; }; /** AnnualTempartureSummariesdata */ AnnualTempartureSummariesdata: { @@ -181,13 +179,13 @@ export interface components { AnnualTemperatureSummariesParameters: { /** * Country - * @default zm_workshops + * @default mw_test * @enum {string} */ country?: "zm" | "mw" | "zm_test" | "mw_test" | "zm_workshops" | "mw_workshops"; /** * Station Id - * @default zambia_eastern + * @default Kasungu */ station_id?: string; /** @@ -214,17 +212,23 @@ export interface components { /** Data */ data: components["schemas"]["AnnualTempartureSummariesdata"][]; }; + /** CropSuccessProbabilitiesMetadata */ + CropSuccessProbabilitiesMetadata: { + start_rains?: components["schemas"]["StartRains"]; + end_rains?: components["schemas"]["EndRains"]; + crops_success?: components["schemas"]["CropsSuccess"]; + }; /** CropSuccessProbabilitiesParameters */ CropSuccessProbabilitiesParameters: { /** * Country - * @default zm_workshops + * @default mw_test * @enum {string} */ country?: "zm" | "mw" | "zm_test" | "mw_test" | "zm_workshops" | "mw_workshops"; /** * Station Id - * @default zambia_eastern + * @default Kasungu */ station_id?: string; /** Water Requirements */ @@ -241,6 +245,25 @@ export interface components { */ override?: boolean; }; + /** CropSuccessProbabilitiesResponce */ + CropSuccessProbabilitiesResponce: { + metadata: components["schemas"]["CropSuccessProbabilitiesMetadata"]; + /** Data */ + data: components["schemas"]["CropSuccessProbabilitiesdata"][]; + }; + /** CropSuccessProbabilitiesdata */ + CropSuccessProbabilitiesdata: { + /** Station */ + station: string; + /** Rain Total */ + rain_total: number; + /** Plant Day */ + plant_day: number; + /** Plant Length */ + plant_length: number; + /** Prop Success */ + prop_success: number; + }; /** CropsSuccess */ CropsSuccess: { /** Water Requirements */ @@ -294,13 +317,13 @@ export interface components { ExtremesSummariesParameters: { /** * Country - * @default zm + * @default mw_test * @enum {string} */ country?: "zm" | "mw" | "zm_test" | "mw_test" | "zm_workshops" | "mw_workshops"; /** * Station Id - * @default test_1 + * @default Kasungu */ station_id?: string; /** @@ -318,23 +341,6 @@ export interface components { */ override?: boolean; }; - /** Forecast */ - Forecast: { - /** - * Date - * Format: date-time - */ - date: string; - /** Filename */ - filename: string; - /** Type */ - type: string; - /** - * Format - * @enum {string} - */ - format: "html" | "pdf"; - }; /** HTTPValidationError */ HTTPValidationError: { /** Detail */ @@ -365,13 +371,13 @@ export interface components { MonthlyTemperatureSummariesParameters: { /** * Country - * @default zm_workshops + * @default mw_test * @enum {string} */ country?: "zm" | "mw" | "zm_test" | "mw_test" | "zm_workshops" | "mw_workshops"; /** * Station Id - * @default zambia_eastern + * @default Kasungu */ station_id?: string; /** @@ -414,13 +420,13 @@ export interface components { SeasonStartProbabilitiesParameters: { /** * Country - * @default zm_workshops + * @default mw_test * @enum {string} */ country?: "zm" | "mw" | "zm_test" | "mw_test" | "zm_workshops" | "mw_workshops"; /** * Station Id - * @default zambia_eastern + * @default Kasungu */ station_id?: string; /** @@ -546,7 +552,7 @@ export interface components { */ country_code: "zm" | "mw" | "zm_test" | "mw_test" | "zm_workshops" | "mw_workshops"; /** Definitions Id */ - definitions_id: string[]; + definitions_id: unknown[]; /** Climsoft List */ climsoft_list?: string[]; data: components["schemas"]["StationDefinitionDataResponce"]; @@ -712,7 +718,7 @@ export interface operations { /** @description Successful Response */ 200: { content: { - "application/json": Record; + "application/json": components["schemas"]["CropSuccessProbabilitiesResponce"]; }; }; /** @description Validation Error */ @@ -834,39 +840,17 @@ export interface operations { }; }; }; - /** - * List Forecasts - * @description Get latest forecasts for country - */ - list_forecasts_v1_forecasts__country_code__get: { + /** Get Documents */ + get_documents_v1_documents__country__get: { parameters: { - path: { - country_code: "zm" | "mw" | "zm_test" | "mw_test" | "zm_workshops" | "mw_workshops"; - }; - }; - responses: { - /** @description Successful Response */ - 200: { - content: { - "application/json": components["schemas"]["Forecast"][]; - }; - }; - /** @description Validation Error */ - 422: { - content: { - "application/json": components["schemas"]["HTTPValidationError"]; - }; + query?: { + prefix?: unknown; + delimiter?: string; + max_results?: number; + match_glob?: string; }; - }; - }; - /** - * Get Forecast - * @description Get forecast file - */ - get_forecast_v1_forecasts__file_name__get: { - parameters: { path: { - file_name: string; + country: "zm" | "mw" | "zm_test" | "mw_test" | "zm_workshops" | "mw_workshops"; }; }; responses: { diff --git a/apps/picsa-tools/climate-tool/src/app/data/stations/mw.ts b/apps/picsa-tools/climate-tool/src/app/data/stations/mw.ts index 5e3bb4e7e..ec15b2d64 100644 --- a/apps/picsa-tools/climate-tool/src/app/data/stations/mw.ts +++ b/apps/picsa-tools/climate-tool/src/app/data/stations/mw.ts @@ -13,119 +13,49 @@ Nalunga: I would remove the last year */ const stations: IStationMeta[] = [ - // 2021-2023 legacy station data - { - id: 'chichiri', - name: 'Chichiri', - latitude: -15.796432, - longitude: 35.026425, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, - }, + // 2021-2023 legacy data (not in climate system) { id: 'chileka', name: 'Chileka', latitude: -15.679203, longitude: 34.967697, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'makanjira', name: 'Makanjira', latitude: -13.7050735, longitude: 35.037632, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, - }, - { - id: 'mangochi', - name: 'Mangochi', - latitude: -14.4821775, - longitude: 35.2352141, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'monkeybay', name: 'Monkeybay', latitude: -14.0806369, longitude: 34.9062036, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'namwera', name: 'Namwera', latitude: -14.3530807, longitude: 35.4706477, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, - }, - // { - // id: 'salima', - // name: 'Salima', - // latitude: -13.78157, - // longitude: 34.4568, - // countryCode: 'mw', - // definitions: CLIMATE_CHART_DEFINTIONS.mw, - // }, - { - id: 'nkhotakota', - name: 'Nkhotakota', - latitude: -12.92842, - longitude: 34.283192, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, - }, - { - id: 'kasungu', - name: 'Kasungu', - latitude: -13.03681, - longitude: 33.48123, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, - }, - // 2024 data - { - id: 'ngabu', - name: 'Ngabu', - latitude: -16.5, - longitude: 34.95, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, + // 2024 M-Climes data (not in climate system) { id: 'nkhatabay', name: 'Nkhatabay', latitude: -11.6, longitude: 34.3, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'chikwawa', name: 'Chikwawa', latitude: -16.03, longitude: 34.78, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, - }, - { - id: 'chitedze', - name: 'Chitedze', - latitude: -13.97, - longitude: 33.63, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'chiradzulu', name: 'Chiradzulu', latitude: -15.7, longitude: 35.18, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, draft: true, }, { @@ -133,73 +63,43 @@ const stations: IStationMeta[] = [ name: 'Dowa_agr', latitude: -13.65, longitude: 33.93, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'kasinthula', name: 'Kasinthula', latitude: -16.1, longitude: 34.8, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'kasiya', name: 'Kasiya', latitude: -13.77, longitude: 33.53, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, draft: true, }, - { - id: 'kia', - name: 'Kia', - latitude: -13.78, - longitude: 33.78, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, - }, { id: 'mponela', name: 'Mponela', latitude: -13.53, longitude: 33.75, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, - }, - { - id: 'salima', - name: 'Salima', - latitude: -13.75, - longitude: 34.58, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'chapananga', name: 'Chapananga', latitude: -15.95, longitude: 34.43, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'golomoti', name: 'Golomoti', latitude: -14.4, longitude: 34.6, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'luwazi', name: 'Luwazi', latitude: -11.5, longitude: 34.2, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, draft: true, }, { @@ -207,8 +107,6 @@ const stations: IStationMeta[] = [ name: 'Mtakataka', latitude: -14.23, longitude: 34.52, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, draft: true, }, { @@ -216,32 +114,24 @@ const stations: IStationMeta[] = [ name: 'Ndakwera', latitude: -16.22, longitude: 34.7, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'chipoka', name: 'Chipoka', latitude: -13.9843, longitude: 34.49223, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'chitala', name: 'Chitala', latitude: -13.68, longitude: 34.25, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, { id: 'kamuona', name: 'Kamuona', latitude: -13.5, longitude: 34.3, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, draft: true, }, { @@ -249,8 +139,6 @@ const stations: IStationMeta[] = [ name: 'Mzandu', latitude: -13.5, longitude: 34.5, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, draft: true, }, { @@ -258,8 +146,6 @@ const stations: IStationMeta[] = [ name: 'Nalunga', latitude: -13.633, longitude: 34.066, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, draft: true, }, { @@ -267,9 +153,159 @@ const stations: IStationMeta[] = [ name: 'Bunda', latitude: -14.18, longitude: 33.77, - countryCode: 'mw', - definitions: CLIMATE_CHART_DEFINTIONS.mw, }, -]; + // climate system + { + id: 'bvumbwe', + name: 'Bvumbwe', + latitude: -15.92, + longitude: 35.07, + district: 'Thyolo', + }, + { + id: 'chichiri', + name: 'Chichiri', + latitude: -15.78, + longitude: 35.05, + district: 'Blantyre', + }, + { + id: 'chileka_airport', + name: 'Chileka Airport', + latitude: -15.67, + longitude: 34.97, + district: 'Blantyre', + }, + { + id: 'makoka', + name: 'Makoka', + latitude: -15.53, + longitude: 35.18, + district: 'Zomba', + }, + { + id: 'mangochi', + name: 'Mangochi', + latitude: -14.47, + longitude: 35.25, + district: 'Mangochi', + }, + { + id: 'monkey_bay', + name: 'Monkey Bay', + latitude: -14.08, + longitude: 34.92, + district: 'Mangochi', + }, + { + id: 'mimosa', + name: 'Mimosa', + latitude: -16.1, + longitude: 35.6, + district: 'Mulanje', + }, + { + id: 'ngabu', + name: 'Ngabu', + latitude: -16.5, + longitude: 34.95, + district: 'Chikwawa', + }, + { + id: 'ntaja', + name: 'Ntaja', + latitude: -14.87, + longitude: 35.53, + district: 'Mahinga', + }, + { + id: 'chitedze', + name: 'Chitedze', + latitude: -13.97, + longitude: 33.63, + district: 'Lilongwe', + }, + { + id: 'dedza', + name: 'Dedza', + latitude: -14.32, + longitude: 34.25, + district: 'Dedza', + }, + { + id: 'kia', + name: 'KIA', + latitude: -13.78, + longitude: 33.78, + district: 'Lilongwe', + }, + { + id: 'kasungu', + name: 'Kasungu', + latitude: -13.02, + longitude: 33.47, + district: 'Kasungu', + }, + { + id: 'nkhotakota', + name: 'Nkhotakota', + latitude: -12.92, + longitude: 34.28, + district: 'Nkhotakota', + }, + { + id: 'salima', + name: 'Salima', + latitude: -13.75, + longitude: 34.58, + district: 'Salima', + }, + { + id: 'bolero', + name: 'Bolero', + latitude: -11.02, + longitude: 33.78, + district: 'Rumphi', + }, + { + id: 'chitipa', + name: 'Chitipa', + latitude: -9.7, + longitude: 33.27, + district: 'Chitipa', + }, + { + id: 'karonga', + name: 'Karonga', + latitude: -9.88, + longitude: 33.95, + district: 'Karonga', + }, + { + id: 'mzimba', + name: 'Mzimba', + latitude: -11.9, + longitude: 33.6, + district: 'Mzimba', + }, + { + id: 'mzuzu', + name: 'Mzuzu', + latitude: -11.43, + longitude: 34.02, + district: 'Mzimba', + }, + { + id: 'nkhata_bay', + name: 'Nkhata Bay', + latitude: -11.6, + longitude: 34.3, + district: 'Nkhata Bay', + }, +].map((station) => ({ + ...station, + countryCode: 'mw', + definitions: CLIMATE_CHART_DEFINTIONS.mw, +})); export default stations; diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/bolero.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/bolero.csv new file mode 100644 index 000000000..7747c4246 --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/bolero.csv @@ -0,0 +1,65 @@ +Year,End,Length,Rainfall,Start +1961,278,,, +1962,288,125,892,163 +1963,263,115,530,148 +1964,272,91,1205,181 +1965,259,104,541,155 +1966,297,142,571,155 +1967,285,130,750,155 +1968,284,123,577,161 +1969,254,86,624,168 +1970,271,129,798,142 +1971,267,117,411,150 +1972,283,125,656,158 +1973,278,105,653,173 +1974,265,104,835,161 +1975,283,121,803,162 +1976,254,,618, +1977,289,129,610,160 +1978,301,136,684,165 +1979,293,148,853,145 +1980,252,76,594,176 +1981,296,,383, +1982,262,115,672,147 +1983,276,111,856,165 +1984,277,119,744,158 +1985,266,121,750,145 +1986,262,103,556,159 +1987,269,107,668,162 +1988,281,109,558,172 +1989,273,119,541,154 +1990,274,91,552,183 +1991,248,73,510,175 +1992,262,89,664,173 +1993,275,,574, +1994,277,121,572,156 +1995,273,96,649,177 +1996,282,111,649,171 +1997,256,93,528,163 +1998,283,,488, +1999,284,,437, +2000,291,115,633,176 +2001,268,,759, +2002,279,112,673,167 +2003,284,118,673,166 +2004,250,100,735,150 +2005,290,,467, +2006,253,105,742,148 +2007,257,91,694,166 +2008,278,129,765,149 +2009,294,119,770,175 +2010,282,,521, +2011,277,100,723,177 +2012,287,121,724,166 +2013,276,,567, +2014,279,107,558,172 +2015,283,113,792,170 +2016,278,119,584,159 +2017,287,118,599,169 +2018,303,130,532,173 +2019,250,89,757,161 +2020,286,130,620,156 +2021,302,,592, +2022,,,, +2023,287,,, +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/bvumbwe.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/bvumbwe.csv new file mode 100644 index 000000000..9946cbdfb --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/bvumbwe.csv @@ -0,0 +1,67 @@ +Year,End,Length,Rainfall,Start +1959,300,,, +1960,297,147,1279,150 +1961,303,296,1083,7 +1962,297,165,1467,132 +1963,272,143,1004,129 +1964,296,288,1120,8 +1965,297,136,701,161 +1966,297,155,1051,142 +1967,295,116,670,179 +1968,281,142,1239,139 +1969,293,138,915,155 +1970,296,173,1139,123 +1971,302,157,986,145 +1972,284,136,867,148 +1973,275,123,1633,152 +1974,295,157,831,138 +1975,296,166,1387,130 +1976,285,127,987,158 +1977,297,149,1162,148 +1978,288,138,719,150 +1979,287,148,921,139 +1980,285,171,1052,114 +1981,295,148,999,147 +1982,273,112,863,161 +1983,301,283,1024,18 +1984,277,160,1542,117 +1985,296,165,1162,131 +1986,292,177,939,115 +1987,303,148,1132,155 +1988,274,119,1256,155 +1989,302,149,924,153 +1990,282,120,948,162 +1991,267,129,707,138 +1992,301,161,1119,140 +1993,270,90,676,180 +1994,267,84,786,183 +1995,280,139,1160,141 +1996,284,134,1760,150 +1997,272,135,1306,137 +1998,285,129,1593,156 +1999,304,110,979,194 +2000,277,148,1512,129 +2001,291,150,1121,141 +2002,272,107,861,165 +2003,302,145,715,157 +2004,299,161,768,138 +2005,273,141,1269,132 +2006,276,140,1139,136 +2007,261,129,1043,132 +2008,297,173,1264,124 +2009,299,159,1015,140 +2010,283,140,1113,143 +2011,276,107,1050,169 +2012,262,98,1161,164 +2013,281,113,971,168 +2014,291,121,1281,170 +2015,282,124,902,158 +2016,291,141,1128,150 +2017,287,167,984,120 +2018,301,,1540, +2019,255,106,1233,149 +2020,303,168,1108,135 +2021,277,,1011, +2022,289,149,1860,140 +2023,278,105,759,173 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/chichiri.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/chichiri.csv index 75e7b76fe..a081cc2ff 100644 --- a/apps/picsa-tools/climate-tool/src/assets/summaries/chichiri.csv +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/chichiri.csv @@ -1,55 +1,62 @@ -Year,Start,End,Length,Rainfall -1965,,264,,823.7 -1966,141,297,156,1078.7 -1967,142,293,151,627.8 -1968,139,287,148,1340.9 -1969,155,290,135,846 -1970,124,276,152,1224.3 -1971,132,302,170,1009.2 -1972,127,284,157,904.5 -1973,159,301,142,1241.7 -1974,131,294,163,917.3 -1975,138,286,148,1292.7 -1976,158,262,104,1277.7 -1977,145,298,153,1322.4 -1978,112,290,178,826.5 -1979,125,290,165,1096.3 -1980,156,300,144,910.2 -1981,161,296,135,1031 -1982,135,266,131,728.3 -1983,156,302,146,1129.8 -1984,117,283,166,1437.2 -1985,133,296,163,1290.8 -1986,115,292,177,1105.2 -1987,145,293,148,1066.5 -1988,117,302,185,1189.8 -1989,142,264,122,861.5 -1990,172,280,108,899.2 -1991,156,299,143,645.5 -1992,138,300,162,1115.6 -1993,136,270,134,825.2 -1994,155,269,114,596.7 -1995,141,280,139,1233.8 -1996,153,283,130,1447.38 -1997,146,283,137,963.1 -1998,145,286,141,1612 -1999,120,284,164,1022 -2000,122,278,156,1237 -2001,141,291,150,1619.2 -2002,158,275,117,1117.24 -2003,180,295,115,829 -2004,177,242,65,639.2 -2005,132,287,155,1266 -2006,136,295,159,1207.1 -2007,155,255,100,1037 -2008,163,266,103,1087.2 -2009,140,291,151,1243 -2010,147,283,136,1066.7 -2011,165,276,111,1055 -2012,163,279,116,1227.8 -2013,142,281,139,858.6 -2014,162,295,133,1540.8 -2015,165,266,101,790.3 -2016,,287,,902.3 -2017,,287,,902.3 -2018,,291,,1571.8 +Year,End,Length,Rainfall,Start +1964,,,, +1965,264,,823, +1966,297,156,1078,141 +1967,293,151,627,142 +1968,287,148,1340,139 +1969,290,135,846,155 +1970,276,152,1224,124 +1971,302,170,1009,132 +1972,284,157,904,127 +1973,301,142,1241,159 +1974,294,163,917,131 +1975,286,148,1292,138 +1976,262,104,1277,158 +1977,298,153,1322,145 +1978,290,178,826,112 +1979,290,165,1096,125 +1980,300,144,910,156 +1981,296,135,1031,161 +1982,266,131,728,135 +1983,302,146,1129,156 +1984,283,166,1437,117 +1985,296,163,1290,133 +1986,292,177,1105,115 +1987,293,148,1066,145 +1988,302,185,1189,117 +1989,264,122,861,142 +1990,280,108,899,172 +1991,299,143,645,156 +1992,300,162,1115,138 +1993,270,134,825,136 +1994,269,114,596,155 +1995,280,139,1233,141 +1996,283,130,1447,153 +1997,283,137,963,146 +1998,286,141,1612,145 +1999,284,164,1022,120 +2000,278,156,1237,122 +2001,291,150,1619,141 +2002,275,117,1117,158 +2003,295,115,829,180 +2004,242,65,639,177 +2005,287,155,1266,132 +2006,295,159,1207,136 +2007,255,100,1037,155 +2008,266,103,1087,163 +2009,291,151,1243,140 +2010,283,136,1066,147 +2011,276,111,1055,165 +2012,279,116,1227,163 +2013,281,139,858,142 +2014,295,133,1540,162 +2015,266,101,790,165 +2016,290,151,1021,139 +2017,287,152,902,135 +2018,291,144,1571,147 +2019,271,124,1100,147 +2020,265,130,862,135 +2021,279,143,1255,136 +2022,264,118,1847,146 +2023,257,80,781,177 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/chileka_airport.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/chileka_airport.csv new file mode 100644 index 000000000..4262ebf13 --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/chileka_airport.csv @@ -0,0 +1,78 @@ +Year,End,Length,Rainfall,Start +1948,261,,, +1949,293,139,1141,154 +1950,267,95,844,172 +1951,247,112,1023,135 +1952,247,95,683,152 +1953,260,105,567,155 +1954,304,171,910,133 +1955,296,142,794,154 +1956,287,148,860,139 +1957,289,144,724,145 +1958,285,125,550,160 +1959,300,146,541,154 +1960,289,145,1007,144 +1961,275,157,854,118 +1962,262,130,1068,132 +1963,273,155,664,118 +1964,289,145,724,144 +1965,293,130,814,163 +1966,297,135,1036,162 +1967,294,,516, +1968,281,119,933,162 +1969,289,137,542,152 +1970,286,157,908,129 +1971,289,145,1010,144 +1972,284,135,484,149 +1973,301,186,1163,115 +1974,278,127,692,151 +1975,287,141,849,146 +1976,270,112,1004,158 +1977,290,147,1115,143 +1978,302,142,1018,160 +1979,283,143,834,140 +1980,269,111,882,158 +1981,293,,651, +1982,281,145,673,136 +1983,272,93,781,179 +1984,278,149,1254,129 +1985,297,187,1001,110 +1986,275,161,852,114 +1987,279,132,1017,147 +1988,261,144,1139,117 +1989,301,148,735,153 +1990,283,130,808,153 +1991,283,149,638,134 +1992,288,116,763,172 +1993,299,,640, +1994,266,84,537,182 +1995,258,117,963,141 +1996,256,103,1186,153 +1997,269,123,966,146 +1998,286,151,933,135 +1999,272,90,758,182 +2000,277,141,1077,136 +2001,294,152,852,142 +2002,272,98,716,174 +2003,297,,599, +2004,211,61,501,150 +2005,270,144,1041,126 +2006,295,130,967,165 +2007,260,125,792,135 +2008,273,124,824,149 +2009,292,152,831,140 +2010,283,130,941,153 +2011,275,106,755,169 +2012,264,106,927,158 +2013,278,98,620,180 +2014,240,78,881,162 +2015,262,103,597,159 +2016,279,121,603,158 +2017,295,170,793,125 +2018,261,120,1222,141 +2019,227,92,627,135 +2020,302,139,855,163 +2021,,,,173 +2022,287,,1219, +2023,294,162,771,132 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/chitedze.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/chitedze.csv index 0c348536e..955c34941 100644 --- a/apps/picsa-tools/climate-tool/src/assets/summaries/chitedze.csv +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/chitedze.csv @@ -1,65 +1,67 @@ -Year,Rainfall,Start,End,Length -1959,486.7,,264, -1960,1055.5,146,303,157 -1961,1029.9,140,291,151 -1962,807.6,157,272,115 -1963,906.4,125,269,144 -1964,759,150,297,147 -1965,478.8,156,245,89 -1966,805.9,162,288,126 -1967,572,162,285,123 -1968,915.3,148,280,132 -1969,945,156,284,128 -1970,1094.4,147,297,150 -1971,909.1,132,300,168 -1972,646,148,285,137 -1973,1135.2,168,302,134 -1974,988.6,158,292,134 -1975,982.8,167,297,130 -1976,980.6,164,304,140 -1977,1101.9,146,279,133 -1978,745.6,138,285,147 -1979,697.9,140,251,111 -1980,896.5,158,287,129 -1981,922.8,180,294,114 -1982,716.9,162,283,121 -1983,698.4,172,259,87 -1984,1062.5,133,284,151 -1985,1018.5,135,276,141 -1986,1139.2,159,291,132 -1987,905.6,164,303,139 -1988,1063.3,172,267,95 -1989,829.8,136,302,166 -1990,602.7,148,289,141 -1991,597.5,165,273,108 -1992,783.7,145,262,117 -1993,844.7,163,275,112 -1994,520.8,170,242,72 -1995,749.1,196,277,81 -1996,780.3,164,283,119 -1997,1154.7,141,259,118 -1998,1291.4,176,285,109 -1999,757.4,166,285,119 -2000,839.3,175,290,115 -2001,785.1,169,267,98 -2002,1029.6,148,271,123 -2003,772.5,167,293,126 -2004,795.8,162,256,94 -2005,708.1,151,287,136 -2006,1005.7,139,282,143 -2007,931.4,168,262,94 -2008,818.9,147,277,130 -2009,911,150,295,145 -2010,730.4,143,281,138 -2011,864.6,184,287,103 -2012,879.9,162,279,117 -2013,722.8,168,281,113 -2014,577.7,183,290,107 -2015,647.4,189,288,99 -2016,850.1,159,254,95 -2017,935.4,149,283,134 -2018,713,161,268,107 -2019,831.1,,272, -2020,796.2,163,267,104 -2021,735.4,192,282,90 -2022,,,, \ No newline at end of file +Year,End,Length,Rainfall,Start +1959,264,,, +1960,303,157,1055,146 +1961,291,151,1029,140 +1962,272,115,807,157 +1963,269,144,906,125 +1964,297,147,759,150 +1965,245,89,478,156 +1966,288,126,805,162 +1967,285,123,572,162 +1968,280,132,915,148 +1969,284,128,945,156 +1970,297,150,1094,147 +1971,300,168,909,132 +1972,285,137,646,148 +1973,302,134,1135,168 +1974,292,134,988,158 +1975,297,130,982,167 +1976,304,140,980,164 +1977,279,133,1101,146 +1978,285,147,745,138 +1979,251,111,697,140 +1980,287,129,896,158 +1981,294,114,922,180 +1982,283,121,716,162 +1983,259,87,698,172 +1984,284,151,1062,133 +1985,276,141,1018,135 +1986,291,132,1139,159 +1987,303,139,905,164 +1988,267,95,1063,172 +1989,302,166,829,136 +1990,289,141,602,148 +1991,273,108,597,165 +1992,262,117,783,145 +1993,275,112,844,163 +1994,242,72,520,170 +1995,277,,749, +1996,283,119,780,164 +1997,259,118,1154,141 +1998,285,109,1291,176 +1999,285,119,757,166 +2000,290,115,839,175 +2001,267,98,785,169 +2002,271,123,1029,148 +2003,293,126,772,167 +2004,256,94,795,162 +2005,287,136,708,151 +2006,282,143,1005,139 +2007,262,94,931,168 +2008,277,130,818,147 +2009,295,145,911,150 +2010,281,138,730,143 +2011,287,103,864,184 +2012,279,117,879,162 +2013,281,113,722,168 +2014,290,107,577,183 +2015,288,,647, +2016,254,95,850,159 +2017,283,134,935,149 +2018,285,120,660,165 +2019,272,108,831,164 +2020,267,,798, +2021,282,188,968,94 +2022,278,,762, +2023,286,110,843,176 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/chitipa.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/chitipa.csv new file mode 100644 index 000000000..6d7582dbf --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/chitipa.csv @@ -0,0 +1,67 @@ +Year,End,Length,Rainfall,Start +1959,292,,, +1960,296,125,837,171 +1961,284,141,1598,143 +1962,296,,603, +1963,269,143,1399,126 +1964,301,129,983,172 +1965,274,120,843,154 +1966,290,125,1027,165 +1967,298,150,1427,148 +1968,299,136,983,163 +1969,288,131,1127,157 +1970,290,141,1205,149 +1971,276,119,767,157 +1972,287,137,825,150 +1973,285,143,740,142 +1974,302,141,932,161 +1975,298,160,986,138 +1976,258,85,694,173 +1977,281,140,1205,141 +1978,282,146,1284,136 +1979,305,159,1074,146 +1980,273,119,681,154 +1981,292,112,726,180 +1982,269,126,989,143 +1983,272,107,1023,165 +1984,282,124,1327,158 +1985,274,141,1203,133 +1986,284,166,1055,118 +1987,272,121,944,151 +1988,286,138,909,148 +1989,288,137,933,151 +1990,288,140,842,148 +1991,284,153,912,131 +1992,274,106,1028,168 +1993,283,104,647,179 +1994,263,112,958,151 +1995,283,,778, +1996,284,123,703,161 +1997,291,134,1319,157 +1998,289,142,839,147 +1999,267,102,578,165 +2000,256,118,933,138 +2001,281,108,790,173 +2002,281,118,932,163 +2003,293,135,883,158 +2004,271,121,1078,150 +2005,285,,935, +2006,262,114,1030,148 +2007,266,102,789,164 +2008,277,126,864,151 +2009,268,135,1039,133 +2010,291,115,730,176 +2011,277,139,1058,138 +2012,288,124,847,164 +2013,282,115,785,167 +2014,279,136,697,143 +2015,284,135,1025,149 +2016,278,120,847,158 +2017,291,138,931,153 +2018,286,131,995,155 +2019,300,153,1272,147 +2020,295,122,856,173 +2021,,,, +2022,,,, +2023,,,, +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/dedza.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/dedza.csv new file mode 100644 index 000000000..eee0cb0c3 --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/dedza.csv @@ -0,0 +1,66 @@ +Year,End,Length,Rainfall,Start +1960,289,,, +1961,303,159,1162,144 +1962,295,120,943,175 +1963,249,121,910,128 +1964,247,75,891,172 +1965,255,124,774,131 +1966,286,117,665,169 +1967,285,123,730,162 +1968,305,157,905,148 +1969,292,139,832,153 +1970,255,105,1056,150 +1971,299,131,702,168 +1972,285,130,695,155 +1973,292,137,971,155 +1974,305,144,871,161 +1975,297,120,944,177 +1976,275,116,1088,159 +1977,291,152,974,139 +1978,273,117,950,156 +1979,291,150,1051,141 +1980,299,145,1111,154 +1981,293,145,967,148 +1982,281,146,905,135 +1983,259,,848, +1984,291,158,1027,133 +1985,269,136,967,133 +1986,290,141,976,149 +1987,302,152,875,150 +1988,304,133,1368,171 +1989,282,133,844,149 +1990,282,116,993,166 +1991,305,161,847,144 +1992,294,127,1131,167 +1993,271,125,766,146 +1994,284,100,715,184 +1995,261,,867, +1996,283,119,1128,164 +1997,284,138,788,146 +1998,275,,737, +1999,264,,741, +2000,273,137,859,136 +2001,266,94,840,172 +2002,273,116,1274,157 +2003,293,128,734,165 +2004,242,74,648,168 +2005,283,121,937,162 +2006,274,126,961,148 +2007,304,144,1022,160 +2008,274,133,978,141 +2009,298,128,1005,170 +2010,284,126,754,158 +2011,277,129,1120,148 +2012,268,103,808,165 +2013,292,126,939,166 +2014,274,103,815,171 +2015,293,135,707,158 +2016,279,109,1029,170 +2017,288,125,826,163 +2018,285,123,1174,162 +2019,269,121,823,148 +2020,270,122,823,148 +2021,283,113,957,170 +2022,,,, +2023,,,, +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/karonga.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/karonga.csv new file mode 100644 index 000000000..94669749c --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/karonga.csv @@ -0,0 +1,66 @@ +Year,End,Length,Rainfall,Start +1960,305,,, +1961,298,159,1617,139 +1962,296,143,1567,153 +1963,286,150,1516,136 +1964,296,116,1280,180 +1965,301,128,1396,173 +1966,303,158,1309,145 +1967,299,150,1282,149 +1968,303,139,986,164 +1969,292,128,926,164 +1970,293,143,1045,150 +1971,288,140,854,148 +1972,287,137,1275,150 +1973,304,139,1346,165 +1974,304,143,1255,161 +1975,298,128,981,170 +1976,299,135,1105,164 +1977,299,122,1211,177 +1978,298,136,1667,162 +1979,294,148,1238,146 +1980,304,145,782,159 +1981,296,,736, +1982,295,,1028, +1983,286,136,1127,150 +1984,284,122,1132,162 +1985,292,148,877,144 +1986,304,138,1134,166 +1987,276,92,784,184 +1988,302,156,780,146 +1989,283,147,797,136 +1990,293,,747, +1991,305,138,955,167 +1992,301,128,856,173 +1993,283,,605, +1994,276,111,941,165 +1995,285,104,633,181 +1996,285,126,532,159 +1997,291,148,1508,143 +1998,290,,869, +1999,303,,762, +2000,293,149,1125,144 +2001,302,129,1312,173 +2002,299,132,914,167 +2003,302,123,1215,179 +2004,280,131,1077,149 +2005,290,124,1062,166 +2006,286,146,796,140 +2007,274,108,907,166 +2008,277,114,1040,163 +2009,273,97,929,176 +2010,284,124,1168,160 +2011,304,153,912,151 +2012,288,121,1084,167 +2013,297,,846, +2014,287,112,562,175 +2015,284,105,715,179 +2016,292,109,1038,183 +2017,295,145,1017,150 +2018,285,115,849,170 +2019,301,154,1418,147 +2020,285,113,896,172 +2021,301,118,758,183 +2022,288,113,1081,175 +2023,287,113,839,174 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/kasungu.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/kasungu.csv index 07a3acf26..6b6a0d49a 100644 --- a/apps/picsa-tools/climate-tool/src/assets/summaries/kasungu.csv +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/kasungu.csv @@ -1,64 +1,66 @@ -Year,Rainfall,Start,End,Length,sum_RainyDays,Jan_spells,Feb_spells,JanFeb_spells,March_spells,OND_spells,max24hourly,sum_RD50 -1960,458.6,,278,,,,7,,9,,51.8,1 -1961,1024.1,160,285,125,70,3,5,5,6,207,55.1,2 -1962,854.8,160,263,103,76,6,4,6,9,198,66,1 -1963,767.4,124,257,133,64,5,5,5,10,192,103.1,1 -1964,751,145,254,109,70,4,2,4,4,93,61.7,1 -1965,667.4,158,296,138,49,10,4,10,14,221,63.5,2 -1966,732,136,289,153,78,4,6,6,3,149,49.5,0 -1967,618.2,157,295,138,56,4,5,5,12,185,61.7,1 -1968,621.3,148,247,99,68,4,2,4,14,159,54.6,1 -1969,666,166,268,102,54,6,12,12,,139,73.4,2 -1970,954.5,150,255,105,77,5,2,5,8,166,80.8,1 -1971,430.3,148,268,120,56,6,5,6,14,153,59.7,1 -1972,583.3,176,284,108,55,7,7,7,11,174,40.6,0 -1973,856.4,157,302,145,73,2,3,3,4,175,55.4,1 -1974,673,145,281,136,61,6,8,8,5,123,48.8,0 -1975,725.7,193,298,105,55,,2,,8,223,68.1,2 -1976,534.1,163,256,93,54,3,9,9,11,164,42.9,0 -1977,880.5,184,279,95,57,4,6,6,7,208,78.7,4 -1978,772.1,163,283,120,48,,4,,11,221,64,4 -1979,1063.8,145,291,146,64,5,12,12,7,198,97.8,3 -1980,1026.8,154,271,117,54,7,3,7,8,47,62.5,5 -1981,714.4,180,291,111,48,13,4,13,5,212,100.3,2 -1982,756.4,163,302,139,63,6,10,10,12,171,74.5,4 -1983,720.8,165,272,107,56,10,5,10,11,193,46,0 -1984,711.1,132,267,135,75,5,5,5,3,171,60.8,1 -1985,1085.9,130,304,174,78,4,3,4,6,177,79.6,3 -1986,793.1,118,253,135,70,7,4,7,12,165,60.5,1 -1987,828.4,203,264,61,58,4,4,4,10,65,91.8,3 -1988,914.5,181,276,95,67,1,4,4,10,166,62.5,1 -1989,817.8,139,273,134,54,10,4,10,18,166,111,5 -1990,781.6,149,282,133,64,5,3,5,6,205,83,2 -1991,504.9,158,272,114,48,6,13,13,7,94,38.6,0 -1992,794,165,272,107,62,6,5,6,6,189,79.4,1 -1993,725.8,135,292,157,46,3,5,5,10,216,92.8,2 -1994,501,187,284,97,44,3,3,3,8,196,97.4,2 -1995,940.8,163,258,95,64,3,5,5,6,219,65.8,4 -1996,838.4,165,283,118,54,7,4,7,12,193,83.9,4 -1997,882.1,141,281,140,58,3,6,6,14,194,69.1,2 -1998,837.8,147,272,125,62,8,6,8,5,191,90.5,1 -1999,537.5,186,252,66,50,12,5,12,6,244,32.6,0 -2000,791.3,165,266,101,66,6,5,6,6,188,59.8,2 -2001,596.8,182,284,102,53,10,8,10,13,229,75.1,1 -2002,1046.2,164,276,112,65,10,4,10,9,60,63.4,2 -2003,812.9,154,280,126,50,5,7,7,16,239,102.5,4 -2004,879.9,149,259,110,58,4,6,6,12,178,105.1,4 -2005,550.7,150,280,130,52,7,15,15,5,162,51.4,1 -2006,1149.3,139,243,104,69,1,6,6,7,185,78.5,6 -2007,576.1,174,253,79,56,2,6,6,16,97,50.8,1 -2008,645.7,150,278,128,66,5,6,6,4,252,40,0 -2009,785.8,165,275,110,63,4,5,5,9,217,49.7,0 -2010,545.6,159,282,123,58,14,7,14,6,101,69.2,2 -2011,860.7,163,276,113,66,3,8,8,5,176,66.7,3 -2012,596.4,165,262,97,48,6,3,6,8,174,87.9,2 -2013,728.3,180,243,63,61,4,2,4,7,224,72.8,1 -2014,725,177,283,106,61,2,3,3,10,189,78.2,2 -2015,610.9,161,266,105,50,12,6,12,7,198,91.6,3 -2016,851.6,197,279,82,57,4,3,4,12,236,80.8,2 -2017,710.4,150,286,136,54,3,11,11,13,227,60.3,2 -2018,660.5,165,285,120,61,9,9,9,5,220,43.8,0 -2019,762.1,164,248,84,60,8,4,8,10,173,71.8,2 -2020,620.1,163,260,97,68,5,7,7,15,18,46.8,0 -2021,669.3,193,284,91,50,4,,,11,278,, -2022,772.1,,,,56,4,6,6,,,, +Year,End,Length,Rainfall,Start +1960,278,,, +1961,285,125,1024,160 +1962,263,103,854,160 +1963,257,133,767,124 +1964,254,109,751,145 +1965,296,138,667,158 +1966,289,122,732,167 +1967,295,138,618,157 +1968,247,99,621,148 +1969,268,102,666,166 +1970,255,105,954,150 +1971,268,120,430,148 +1972,284,108,583,176 +1973,302,127,856,175 +1974,281,136,673,145 +1975,298,,725, +1976,256,93,534,163 +1977,279,95,880,184 +1978,283,120,772,163 +1979,291,146,1063,145 +1980,271,117,1026,154 +1981,291,111,714,180 +1982,302,139,756,163 +1983,272,107,720,165 +1984,267,135,711,132 +1985,304,174,1085,130 +1986,253,135,793,118 +1987,264,,828, +1988,276,95,914,181 +1989,273,134,817,139 +1990,282,133,781,149 +1991,272,114,504,158 +1992,272,107,794,165 +1993,292,,725, +1994,284,,501, +1995,258,95,940,163 +1996,283,118,838,165 +1997,281,140,882,141 +1998,272,94,837,178 +1999,252,,537, +2000,266,101,791,165 +2001,284,,596, +2002,276,112,1046,164 +2003,280,126,812,154 +2004,259,110,879,149 +2005,280,130,550,150 +2006,243,104,1149,139 +2007,253,79,576,174 +2008,278,128,645,150 +2009,275,110,785,165 +2010,282,123,545,159 +2011,276,,860, +2012,262,97,596,165 +2013,243,63,728,180 +2014,283,106,725,177 +2015,266,105,610,161 +2016,279,,851, +2017,286,136,710,150 +2018,285,120,660,165 +2019,248,84,762,164 +2020,260,97,620,163 +2021,284,,669, +2022,276,122,936,154 +2023,273,99,702,174 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/kia.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/kia.csv index 3d6c32527..52e5581f9 100644 --- a/apps/picsa-tools/climate-tool/src/assets/summaries/kia.csv +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/kia.csv @@ -1,64 +1,66 @@ -Year,Rainfall,Start,End,Length -1960,611.4,,303, -1961,900.4,140,282,142 -1962,828.3,132,259,127 -1963,658.4,171,269,98 -1964,924.1,150,252,102 -1965,531.1,156,273,117 -1966,734.1,162,297,135 -1967,541,156,285,129 -1968,1065,152,287,135 -1969,840.3,165,293,128 -1970,949.2,149,273,124 -1971,700.5,132,282,150 -1972,620.8,157,303,146 -1973,1001.5,171,279,108 -1974,889.8,160,282,122 -1975,801.9,167,280,113 -1976,1149.4,168,284,116 -1977,783.8,183,289,106 -1978,1074.9,145,294,149 -1979,757.3,141,283,142 -1980,1006,154,285,131 -1981,783.1,180,248,68 -1982,636.3,162,280,118 -1983,699.1,172,275,103 -1984,1175.2,162,285,123 -1985,733.4,131,276,145 -1986,705.6,118,292,174 -1987,698.5,158,265,107 -1988,1072.6,174,274,100 -1989,828.5,136,305,169 -1990,774.4,180,282,102 -1991,757.9,137,273,136 -1992,995.1,173,275,102 -1993,681.3,185,272,87 -1994,740,153,252,99 -1995,1094.6,161,259,98 -1996,904.7,164,284,120 -1997,809.8,161,284,123 -1998,967.6,148,266,118 -1999,628.2,183,268,85 -2000,793.8,122,264,142 -2001,996.9,171,269,98 -2002,1110.7,164,271,107 -2003,625.9,153,293,140 -2004,853.4,147,280,133 -2005,781.2,155,273,118 -2006,720.4,179,268,89 -2007,791.6,160,261,101 -2008,805,158,268,110 -2009,695.7,128,262,134 -2010,729.8,147,260,113 -2011,1007.1,172,277,105 -2012,959.7,148,279,131 -2013,713.6,159,281,122 -2014,639.8,172,283,111 -2015,797.9,151,276,125 -2016,807,173,270,97 -2017,574.4,177,257,80 -2018,902,164,285,121 -2019,927.5,149,262,113 -2020,793.4,153,273,120 -2021,450.3,,, -2022,0,,, \ No newline at end of file +Year,End,Length,Rainfall,Start +1960,303,,, +1961,282,142,900,140 +1962,259,127,828,132 +1963,269,98,658,171 +1964,252,102,924,150 +1965,273,117,531,156 +1966,297,135,734,162 +1967,285,129,541,156 +1968,287,135,1065,152 +1969,293,128,840,165 +1970,273,124,949,149 +1971,282,150,700,132 +1972,303,146,620,157 +1973,279,108,1001,171 +1974,282,122,889,160 +1975,280,113,801,167 +1976,284,116,1149,168 +1977,289,106,783,183 +1978,294,149,1074,145 +1979,283,142,757,141 +1980,285,131,1006,154 +1981,248,68,783,180 +1982,280,118,636,162 +1983,275,103,699,172 +1984,285,123,1175,162 +1985,276,145,733,131 +1986,292,174,705,118 +1987,265,107,698,158 +1988,274,100,1072,174 +1989,305,169,828,136 +1990,282,102,774,180 +1991,273,136,757,137 +1992,275,102,995,173 +1993,272,,681, +1994,252,99,740,153 +1995,259,98,1094,161 +1996,284,120,904,164 +1997,284,123,809,161 +1998,266,118,967,148 +1999,268,85,628,183 +2000,264,142,793,122 +2001,269,98,996,171 +2002,271,107,1110,164 +2003,293,140,625,153 +2004,280,133,853,147 +2005,273,118,781,155 +2006,268,89,720,179 +2007,261,101,791,160 +2008,268,110,805,158 +2009,262,134,695,128 +2010,260,113,729,147 +2011,277,105,1007,172 +2012,279,131,959,148 +2013,281,122,713,159 +2014,283,111,639,172 +2015,276,125,797,151 +2016,270,97,807,173 +2017,257,80,574,177 +2018,285,121,902,164 +2019,262,113,927,149 +2020,273,120,793,153 +2021,,,, +2022,,,, +2023,257,,912, +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/makoka.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/makoka.csv new file mode 100644 index 000000000..6f3de80d0 --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/makoka.csv @@ -0,0 +1,63 @@ +Year,End,Length,Rainfall,Start +1963,,,, +1964,289,,, +1965,259,111,999,148 +1966,296,131,930,165 +1967,294,131,659,163 +1968,286,152,826,134 +1969,293,136,1022,157 +1970,291,169,1279,122 +1971,303,171,1133,132 +1972,284,135,830,149 +1973,291,132,939,159 +1974,281,136,666,145 +1975,296,158,963,138 +1976,269,,608, +1977,279,132,1280,147 +1978,264,152,768,112 +1979,252,135,642,117 +1980,263,106,1047,157 +1981,296,118,843,178 +1982,298,137,920,161 +1983,273,118,994,155 +1984,283,124,1368,159 +1985,280,147,1391,133 +1986,276,171,893,105 +1987,302,151,1078,151 +1988,267,163,1219,104 +1989,300,147,974,153 +1990,297,158,1150,139 +1991,266,121,559,145 +1992,291,124,810,167 +1993,270,98,535,172 +1994,284,128,587,156 +1995,280,116,918,164 +1996,283,131,1592,152 +1997,266,153,988,113 +1998,286,175,1171,111 +1999,288,159,759,129 +2000,271,143,1161,128 +2001,291,150,833,141 +2002,274,150,935,124 +2003,279,138,684,141 +2004,302,153,885,149 +2005,272,118,1246,154 +2006,276,140,999,136 +2007,252,95,1112,157 +2008,274,127,1054,147 +2009,299,153,1041,146 +2010,282,135,1149,147 +2011,271,102,991,169 +2012,262,81,736,181 +2013,303,132,842,171 +2014,266,96,1084,170 +2015,266,,568, +2016,266,117,923,149 +2017,286,122,556,164 +2018,294,144,1163,150 +2019,255,115,1001,140 +2020,270,107,1015,163 +2021,283,,, +2022,,,, +2023,303,,815, +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/mangochi.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/mangochi.csv index f69fdbc33..576c07f32 100644 --- a/apps/picsa-tools/climate-tool/src/assets/summaries/mangochi.csv +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/mangochi.csv @@ -1,59 +1,66 @@ -Year,Start,End,Length,Rainfall -1960,,297,,625.0939999 -1961,168,300,132,759.4599991 -1962,132,271,139,927.6080008 -1963,128,267,139,862.8379998 -1964,149,276,127,708.6600003 -1965,186,256,70,672.592 -1966,163,297,134,1005.331999 -1967,199,285,86,589.7879994 -1968,161,284,123,816.3560002 -1969,188,254,66,480.568 -1970,148,256,108,804.417999 -1971,168,290,122,541.2739995 -1972,171,302,131,589.279999 -1973,171,302,131,895.6039999 -1974,151,281,130,797.8139999 -1975,147,283,136,1287.78 -1976,162,270,108,653.5419993 -1977,161,278,117,1120.901999 -1978,159,290,131,1059.687999 -1979,139,293,154,794.2579997 -1980,216,270,54,541.6379995 -1981,180,275,95,730.7 -1982,,254,,393.3000001 -1983,151,274,123,1015.4 -1984,195,284,89,563.6999996 -1985,188,275,87,685.0599995 -1986,187,292,105,509.2880001 -1987,196,263,67,525.26 -1988,201,275,74,815.8199999 -1989,186,273,87,493.0299997 -1990,184,268,84,758.52 -1991,162,268,106,474.5000002 -1992,171,294,123,762.2000005 -1993,129,272,143,295.5 -1994,185,238,53,325.4000001 -1995,161,296,135,753.3999999 -1996,166,284,118,1028.5 -1997,157,266,109,627.9000001 -1998,162,284,122,605.8999996 -1999,166,286,120,653.8 -2000,122,289,167,1256.499999 -2001,163,243,80,776.8999999 -2002,148,277,129,1027.1 -2003,202,276,74,487.1000001 -2004,134,302,168,692.2000005 -2005,167,285,118,875.7999997 -2006,135,304,169,1157.6 -2007,118,244,126,868.4999998 -2008,141,297,156,810.6999996 -2009,164,285,121,829.6000001 -2010,143,283,140,680.5000002 -2011,150,276,126,846.5000005 -2012,163,298,,793.0999997 -2013,166,264,98,914.7000003 -2014,183,291,108,1127.099999 -2015,149,266,117,694.8999994 -2016,,279,,979.700001 -2017,,288,,825.7999997 \ No newline at end of file +Year,End,Length,Rainfall,Start +1960,297,,, +1961,300,132,759,168 +1962,271,139,927,132 +1963,267,139,862,128 +1964,276,127,708,149 +1965,256,,672, +1966,297,134,1005,163 +1967,285,,589, +1968,284,123,816,161 +1969,254,,480, +1970,256,108,804,148 +1971,290,122,541,168 +1972,302,131,589,171 +1973,302,131,895,171 +1974,281,130,797,151 +1975,283,136,1287,147 +1976,270,108,653,162 +1977,278,117,1120,161 +1978,290,131,1059,159 +1979,293,154,794,139 +1980,270,,541, +1981,275,95,730,180 +1982,254,,393, +1983,274,123,1015,151 +1984,284,,563, +1985,275,,685, +1986,292,,509, +1987,263,,525, +1988,275,,815, +1989,273,,493, +1990,268,84,758,184 +1991,268,106,474,162 +1992,294,123,762,171 +1993,272,143,295,129 +1994,238,,325, +1995,296,135,753,161 +1996,284,118,1028,166 +1997,266,109,627,157 +1998,284,122,605,162 +1999,286,120,653,166 +2000,289,167,1256,122 +2001,243,80,776,163 +2002,277,129,1027,148 +2003,276,,487, +2004,302,168,692,134 +2005,285,118,875,167 +2006,304,169,1157,135 +2007,244,126,868,118 +2008,297,156,810,141 +2009,285,121,829,164 +2010,283,140,680,143 +2011,276,126,846,150 +2012,298,135,793,163 +2013,264,98,914,166 +2014,291,108,1127,183 +2015,266,117,694,149 +2016,279,119,979,160 +2017,288,156,825,132 +2018,305,162,936,143 +2019,239,90,783,149 +2020,303,123,697,180 +2021,262,,588, +2022,290,118,1133,172 +2023,298,,324, +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/mimosa.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/mimosa.csv new file mode 100644 index 000000000..735fd9074 --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/mimosa.csv @@ -0,0 +1,69 @@ +Year,End,Length,Rainfall,Start +1957,291,,, +1958,292,164,1224,128 +1959,301,175,1427,126 +1960,298,153,1368,145 +1961,303,181,1621,122 +1962,297,159,2207,138 +1963,305,152,1147,153 +1964,296,151,1398,145 +1965,303,207,1184,96 +1966,299,166,1349,133 +1967,294,169,1070,125 +1968,299,165,1733,134 +1969,299,180,1426,119 +1970,257,113,1384,144 +1971,282,154,1282,128 +1972,300,169,1209,131 +1973,302,174,1816,128 +1974,295,165,1042,130 +1975,301,163,1656,138 +1976,286,124,1199,162 +1977,302,175,1579,127 +1978,290,136,1441,154 +1979,293,150,1358,143 +1980,305,148,1690,157 +1981,295,178,1321,117 +1982,300,199,1051,101 +1983,297,159,1433,138 +1984,289,172,1662,117 +1985,296,163,1746,133 +1986,292,177,1049,115 +1987,305,155,1383,150 +1988,304,200,2245,104 +1989,299,164,1465,135 +1990,297,149,1298,148 +1991,300,156,543,144 +1992,304,177,1472,127 +1993,300,183,1268,117 +1994,286,133,1015,153 +1995,297,154,1549,143 +1996,284,135,1431,149 +1997,273,172,1649,101 +1998,305,160,1995,145 +1999,304,166,955,138 +2000,281,159,2176,122 +2001,291,154,1615,137 +2002,281,164,1380,117 +2003,305,151,826,154 +2004,264,114,924,150 +2005,303,172,1656,131 +2006,276,157,1444,119 +2007,261,144,1621,117 +2008,286,126,1527,160 +2009,300,142,1206,158 +2010,284,135,1100,149 +2011,287,190,1671,97 +2012,298,156,1607,142 +2013,302,209,1261,93 +2014,285,115,2123,170 +2015,286,147,3222,139 +2016,301,162,1731,139 +2017,305,185,1424,120 +2018,303,150,1145,153 +2019,255,89,1160,166 +2020,297,154,1130,143 +2021,303,168,1673,135 +2022,291,165,,126 +2023,294,,1114, +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/mzimba.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/mzimba.csv new file mode 100644 index 000000000..d86fc95fb --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/mzimba.csv @@ -0,0 +1,67 @@ +Year,End,Length,Rainfall,Start +1959,278,,, +1960,297,131,793,166 +1961,276,138,945,138 +1962,272,87,694,185 +1963,268,140,892,128 +1964,287,138,986,149 +1965,258,102,709,156 +1966,282,117,821,165 +1967,297,140,810,157 +1968,291,128,703,163 +1969,255,84,543,171 +1970,302,152,1306,150 +1971,299,164,663,135 +1972,279,125,804,154 +1973,295,137,988,158 +1974,304,143,985,161 +1975,279,109,1076,170 +1976,285,125,818,160 +1977,299,139,797,160 +1978,300,165,1166,135 +1979,293,134,912,159 +1980,273,98,891,175 +1981,295,143,912,152 +1982,292,159,958,133 +1983,286,113,751,173 +1984,283,146,967,137 +1985,269,136,998,133 +1986,275,117,820,158 +1987,294,112,835,182 +1988,282,110,995,172 +1989,273,136,1086,137 +1990,281,112,707,169 +1991,272,96,741,176 +1992,285,147,762,138 +1993,273,85,781,188 +1994,269,121,902,148 +1995,273,110,876,163 +1996,281,111,556,170 +1997,281,120,789,161 +1998,282,136,925,146 +1999,255,70,692,185 +2000,269,147,1147,122 +2001,287,111,932,176 +2002,279,114,771,165 +2003,293,128,905,165 +2004,277,130,938,147 +2005,289,117,641,172 +2006,283,146,898,137 +2007,267,102,737,165 +2008,278,132,779,146 +2009,294,166,621,128 +2010,282,87,787,195 +2011,275,147,720,128 +2012,262,87,555,175 +2013,276,106,1118,170 +2014,274,87,469,187 +2015,279,107,861,172 +2016,299,109,682,190 +2017,287,123,888,164 +2018,271,106,905,165 +2019,271,119,992,152 +2020,272,,907, +2021,302,201,849,101 +2022,288,113,966,175 +2023,287,,, +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/mzuzu.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/mzuzu.csv new file mode 100644 index 000000000..3349b1896 --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/mzuzu.csv @@ -0,0 +1,66 @@ +Year,End,Length,Rainfall,Start +1960,305,,, +1961,305,299,1496,6 +1962,299,120,1183,179 +1963,285,147,1341,138 +1964,290,283,1014,7 +1965,298,145,1253,153 +1966,298,123,1167,175 +1967,296,152,1279,144 +1968,292,166,1117,126 +1969,293,122,867,171 +1970,295,145,1306,150 +1971,295,119,771,176 +1972,302,143,953,159 +1973,292,137,1110,155 +1974,301,139,1460,162 +1975,301,144,1263,157 +1976,286,137,802,149 +1977,302,142,1317,160 +1978,296,156,1347,140 +1979,305,166,1189,139 +1980,298,140,804,158 +1981,299,145,1124,154 +1982,303,169,1015,134 +1983,305,136,1116,169 +1984,301,138,1417,163 +1985,303,169,1249,134 +1986,292,167,905,125 +1987,305,143,974,162 +1988,284,162,1366,122 +1989,283,145,789,138 +1990,289,140,1366,149 +1991,305,152,562,153 +1992,305,132,805,173 +1993,300,113,836,187 +1994,284,132,761,152 +1995,298,149,1225,149 +1996,279,109,792,170 +1997,293,287,1056,6 +1998,305,109,1570,196 +1999,304,138,994,166 +2000,291,150,1028,141 +2001,292,104,1084,188 +2002,287,158,1197,129 +2003,305,150,1102,155 +2004,271,115,950,156 +2005,301,135,955,166 +2006,288,140,1085,148 +2007,299,148,1177,151 +2008,297,111,907,186 +2009,305,171,1167,134 +2010,305,152,844,153 +2011,300,149,969,151 +2012,299,134,1070,165 +2013,303,133,1272,170 +2014,298,123,912,175 +2015,293,146,1374,147 +2016,302,95,821,207 +2017,290,168,1034,122 +2018,303,128,707,175 +2019,294,131,1070,163 +2020,293,108,1025,185 +2021,302,,, +2022,292,,, +2023,303,165,1001,138 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/ngabu.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/ngabu.csv index 0ad2c23aa..5f8ff9ec7 100644 --- a/apps/picsa-tools/climate-tool/src/assets/summaries/ngabu.csv +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/ngabu.csv @@ -1,65 +1,67 @@ -Year,Rainfall,Start,End,Length -1959,407.8,,263, -1960,496.7,150,297,147 -1961,736.7,168,303,135 -1962,922.1,145,273,128 -1963,470.1,176,257,81 -1964,764.4,146,254,108 -1965,517.1,153,295,142 -1966,702.3,162,297,135 -1967,503.5,203,294,91 -1968,731,162,266,104 -1969,631.3,156,284,128 -1970,685.1,141,257,116 -1971,635.4,144,292,148 -1972,815.1,149,302,153 -1973,879.3,175,302,127 -1974,499.9,158,293,135 -1975,779.6,152,301,149 -1976,727,150,271,121 -1977,958.8,150,292,142 -1978,785.3,161,275,114 -1979,487,150,252,102 -1980,689.7,157,304,147 -1981,837.7,182,293,111 -1982,405.9,207,261,54 -1983,1021.5,155,297,142 -1984,1010.7,130,285,155 -1985,863.8,133,302,169 -1986,554.3,115,291,176 -1987,902,155,287,132 -1988,1030.5,104,305,201 -1989,593.5,136,268,132 -1990,770.7,172,287,115 -1991,273.5,304,304,0 -1992,743.2,161,294,133 -1993,566.1,129,299,170 -1994,540.9,185,249,64 -1995,826.9,150,248,98 -1996,937.9,150,278,128 -1997,766.2,141,258,117 -1998,990.3,165,302,137 -1999,881,195,285,90 -2000,1075.1,119,266,147 -2001,743.7,176,275,99 -2002,716.4,167,251,84 -2003,530.9,201,294,93 -2004,463.3,150,243,93 -2005,785.3,146,294,148 -2006,976.3,136,276,140 -2007,970.7,155,261,106 -2008,542.1,160,280,120 -2009,490,145,299,154 -2010,574.6,147,254,107 -2011,658.5,183,275,92 -2012,752.9,159,278,119 -2013,630.7,166,302,136 -2014,1001.4,183,275,92 -2015,554.5,199,282,83 -2016,850.1,158,278,120 -2017,387,167,284,117 -2018,953.5,145,268,123 -2019,589.6,178,248,70 -2020,566.3,159,271,112 -2021,1042.3,188,302,114 -2022,0,,, \ No newline at end of file +Year,End,Length,Rainfall,Start +1959,263,,, +1960,297,147,496,150 +1961,303,135,736,168 +1962,273,128,922,145 +1963,257,81,470,176 +1964,254,108,764,146 +1965,295,142,517,153 +1966,297,135,702,162 +1967,294,,503, +1968,266,104,731,162 +1969,284,128,631,156 +1970,257,116,685,141 +1971,292,148,635,144 +1972,302,153,815,149 +1973,302,127,879,175 +1974,293,135,499,158 +1975,301,149,779,152 +1976,271,121,727,150 +1977,292,142,958,150 +1978,275,114,785,161 +1979,252,102,487,150 +1980,304,147,689,157 +1981,293,111,837,182 +1982,261,,405, +1983,297,142,1021,155 +1984,285,155,1010,130 +1985,302,169,863,133 +1986,291,176,554,115 +1987,287,132,902,155 +1988,305,201,1030,104 +1989,268,132,593,136 +1990,287,115,770,172 +1991,304,,273, +1992,294,133,743,161 +1993,299,170,566,129 +1994,249,,540, +1995,248,98,826,150 +1996,278,128,937,150 +1997,258,117,766,141 +1998,302,137,990,165 +1999,285,,881, +2000,266,147,1075,119 +2001,275,99,743,176 +2002,251,84,716,167 +2003,294,,530, +2004,243,93,463,150 +2005,294,148,785,146 +2006,276,140,976,136 +2007,261,106,970,155 +2008,280,120,542,160 +2009,299,154,490,145 +2010,254,107,574,147 +2011,275,92,658,183 +2012,278,119,752,159 +2013,302,136,630,166 +2014,275,92,1001,183 +2015,282,,554, +2016,278,120,850,158 +2017,284,117,387,167 +2018,268,123,953,145 +2019,248,70,589,178 +2020,271,112,566,159 +2021,302,,1042, +2022,258,,948, +2023,286,164,730,122 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/nkhata_bay.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/nkhata_bay.csv new file mode 100644 index 000000000..7f0fe7988 --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/nkhata_bay.csv @@ -0,0 +1,67 @@ +Year,End,Length,Rainfall,Start +1959,302,,, +1960,304,137,1435,167 +1961,305,172,2129,133 +1962,305,146,1782,159 +1963,305,143,1043,162 +1964,297,162,1635,135 +1965,300,126,1105,174 +1966,,,,154 +1967,297,,, +1968,300,165,1696,135 +1969,287,123,1379,164 +1970,297,153,1108,144 +1971,296,150,1381,146 +1972,301,151,1580,150 +1973,303,131,1672,172 +1974,301,145,1435,156 +1975,302,117,1608,185 +1976,285,128,1208,157 +1977,303,175,1869,128 +1978,297,158,2128,139 +1979,300,160,1410,140 +1980,305,138,1488,167 +1981,301,144,1372,157 +1982,286,150,1109,136 +1983,299,127,841,172 +1984,289,123,1012,166 +1985,304,173,1593,131 +1986,304,149,929,155 +1987,304,146,1290,158 +1988,301,168,1412,133 +1989,296,288,1249,8 +1990,304,145,1777,159 +1991,305,131,808,174 +1992,305,160,1252,145 +1993,305,135,1160,170 +1994,292,140,1519,152 +1995,304,145,1683,159 +1996,305,123,1231,182 +1997,292,286,1735,6 +1998,304,158,2043,146 +1999,305,302,804,3 +2000,295,156,1421,139 +2001,301,144,1727,157 +2002,288,157,1400,131 +2003,305,158,1585,147 +2004,303,134,924,169 +2005,304,138,1297,166 +2006,304,156,1234,148 +2007,297,294,1345,3 +2008,297,285,1412,12 +2009,305,138,1317,167 +2010,285,267,978,18 +2011,291,140,1320,151 +2012,305,155,1770,150 +2013,303,158,1731,145 +2014,298,157,1397,141 +2015,301,132,1528,169 +2016,302,119,1337,183 +2017,305,155,1718,150 +2018,305,159,867,146 +2019,294,147,1589,147 +2020,295,111,1371,184 +2021,303,,, +2022,292,,1225, +2023,303,177,1589,126 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/nkhotakota.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/nkhotakota.csv index eccb41254..c8e77816f 100644 --- a/apps/picsa-tools/climate-tool/src/assets/summaries/nkhotakota.csv +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/nkhotakota.csv @@ -1,66 +1,67 @@ -Year,Start,Length,Rainfall,End,sum_RainyDays,Jan_spells,Feb_spells,JanFeb_spells,March_spells,OND_spells,max24hourly,sum_RD50 -1959,,,937.3,300,59,,3,,5,,71.9,2 -1960,167,131,1555.484,298,81,4,1,4,4,120,119.38,4 -1961,138,162,1813.412,300,106,3,7,7,6,43,155.194,6 -1962,150,145,1654.542,295,96,4,2,4,5,92,182.118,9 -1963,124,158,1482.1836,282,82,1,5,5,12,93,171.196,3 -1964,171,131,1722.9836,302,79,7,5,7,3,96,120.65,10 -1965,171,95,1295.888,266,70,5,3,5,7,93,74.422,9 -1966,163,139,1376.906,302,98,3,2,3,5,79,120.9,5 -1967,120,179,1253.702,299,82,8,4,8,5,50,58.928,3 -1968,151,148,1602.0342,299,90,3,4,4,3,126,128.016,7 -1969,164,135,1271.754,299,73,7,5,7,7,76,138.938,7 -1970,149,148,1760.182,297,93,4,4,4,7,100,117.348,7 -1971,170,128,1829.308,298,83,6,5,6,5,154,125.222,9 -1972,153,149,1753.108,302,81,4,4,4,7,81,128.016,10 -1973,168,134,1568.196,302,100,1,4,4,3,73,103.378,5 -1974,158,145,1331.468,303,74,6,8,8,4,118,119.634,7 -1975,157,141,2167.382,298,99,3,3,3,2,121,141.732,12 -1976,163,136,1341.918,299,80,4,10,10,2,114,83.312,5 -1977,147,151,2225.294,298,105,4,3,4,3,33,228.346,13 -1978,135,160,1981.962,295,91,7,5,7,2,54,197.358,8 -1979,142,151,1640.586,293,96,5,6,6,3,103,81.788,7 -1980,156,144,1724.2,300,72,8,2,8,5,76,213.4,7 -1981,152,144,1762.7,296,84,5,6,6,11,43,149.9,10 -1982,140,162,1063.4,302,73,4,6,6,3,116,59.6,3 -1983,165,110,924.7,275,70,12,4,12,2,123,76.5,2 -1984,132,152,1531.4,284,79,5,4,5,5,46,129.4,5 -1985,139,164,2099.9,303,99,2,7,7,8,26,185.8,9 -1986,161,131,1212,292,76,3,3,3,9,145,66,5 -1987,166,137,1200,303,83,2,5,5,5,90,71.9,2 -1988,171,130,1647.6,301,92,5,5,5,2,138,159.8,8 -1989,153,143,1359.1,296,68,9,4,9,16,113,117.8,9 -1990,164,118,1183.46,282,74,3,7,7,8,152,118,6 -1991,180,119,873.3,299,53,10,10,10,7,66,87,5 -1992,168,137,1286,305,70,2,2,2,,209,113,8 -1993,168,116,883.4,284,65,7,4,7,11,59,80.6,3 -1994,148,137,1062.4,285,63,4,6,6,4,185,80.5,5 -1995,161,121,1052.6,282,77,9,2,9,4,74,85.5,3 -1996,168,124,985.9,292,57,5,,,,102,59.5,3 -1997,154,135,1574.1,289,81,3,7,7,4,103,121.8,8 -1998,187,116,1174,303,70,2,5,5,3,51,94.6,6 -1999,165,135,833.9,300,68,4,4,4,4,64,53.4,1 -2000,154,127,1429.5,281,102,2,2,2,2,89,74.8,3 -2001,158,131,1401.6,289,84,3,4,4,6,86,125.8,5 -2002,163,116,1172.9,279,63,7,9,9,16,60,67.6,7 -2003,153,151,1284.2,304,75,4,6,6,7,53,71.8,5 -2004,151,145,1260,296,70,3,8,8,11,97,100.1,6 -2005,182,118,1354.4,300,73,3,3,3,6,141,113.4,3 -2006,164,135,1301.4,299,79,3,6,6,5,73,155.2,4 -2007,154,144,1495.6,298,76,4,8,8,9,183,87.3,6 -2008,149,130,1781.5,279,80,7,2,7,5,113,100.3,9 -2009,165,135,1428.8,300,75,4,2,4,9,114,85.6,7 -2010,153,131,1320.1,284,66,8,5,8,2,110,130.6,6 -2011,164,113,1448.2,277,69,4,7,7,7,95,226.7,6 -2012,163,116,1295.2,279,68,3,4,4,5,202,141.6,5 -2013,146,157,1519.3,303,71,3,4,4,6,34,237.5,5 -2014,172,119,1065,291,65,2,3,3,7,197,91.5,2 -2015,163,117,815.7,280,59,5,9,9,7,183,83.4,2 -2016,159,146,1200.6,305,71,5,5,5,5,203,69.7,3 -2017,142,153,1548.7,295,81,10,7,10,5,164,119.8,5 -2018,142,146,1487.5,288,68,4,6,6,7,172,140,7 -2019,149,146,1550.1,295,64,9,6,9,7,168,124.1,8 -2020,155,113,1158.1,268,72,5,,,3,174,, -2021,170,131,1166.6,301,67,,2,,5,233,, -2022,140,151,1400.6,291,78,2,6,6,4,197,,7 -2023,,,,,,,,,,,, +Year,End,Length,Rainfall,Start +1959,300,,, +1960,298,131,1555,167 +1961,300,162,1813,138 +1962,295,145,1654,150 +1963,282,158,1482,124 +1964,302,131,1722,171 +1965,266,95,1295,171 +1966,302,139,1376,163 +1967,299,179,1253,120 +1968,299,148,1602,151 +1969,299,135,1271,164 +1970,297,148,1760,149 +1971,298,128,1829,170 +1972,302,149,1753,153 +1973,302,134,1568,168 +1974,303,145,1331,158 +1975,298,141,2167,157 +1976,299,136,1341,163 +1977,298,151,2225,147 +1978,295,139,1981,156 +1979,293,151,1640,142 +1980,300,144,1724,156 +1981,296,144,1762,152 +1982,302,162,1063,140 +1983,275,110,924,165 +1984,284,152,1531,132 +1985,303,164,2099,139 +1986,292,131,1212,161 +1987,303,137,1200,166 +1988,301,130,1647,171 +1989,296,143,1359,153 +1990,282,118,1183,164 +1991,299,,873, +1992,305,137,1286,168 +1993,284,116,883,168 +1994,285,137,1062,148 +1995,282,121,1052,161 +1996,292,124,985,168 +1997,289,135,1574,154 +1998,303,,1174, +1999,300,135,833,165 +2000,281,127,1429,154 +2001,289,131,1401,158 +2002,279,116,1172,163 +2003,304,151,1284,153 +2004,296,145,1260,151 +2005,300,118,1354,182 +2006,299,135,1301,164 +2007,298,144,1495,154 +2008,279,130,1781,149 +2009,300,135,1428,165 +2010,284,131,1320,153 +2011,277,113,1448,164 +2012,279,116,1295,163 +2013,303,157,1519,146 +2014,291,119,1065,172 +2015,280,117,815,163 +2016,305,146,1200,159 +2017,295,153,1548,142 +2018,288,146,1487,142 +2019,295,146,1550,149 +2020,268,113,1158,155 +2021,301,,1381, +2022,291,151,1400,140 +2023,287,133,1726,154 +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/ntaja.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/ntaja.csv new file mode 100644 index 000000000..64125d204 --- /dev/null +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/ntaja.csv @@ -0,0 +1,57 @@ +Year,End,Length,Rainfall,Start +1969,,,, +1970,291,,879, +1971,291,147,829,144 +1972,284,136,669,148 +1973,305,175,1198,130 +1974,280,128,698,152 +1975,295,148,1008,147 +1976,274,98,693,176 +1977,298,119,1344,179 +1978,302,144,923,158 +1979,294,156,854,138 +1980,260,103,866,157 +1981,295,111,783,184 +1982,280,117,854,163 +1983,271,125,764,146 +1984,283,124,849,159 +1985,283,151,1080,132 +1986,297,142,1111,155 +1987,304,150,854,154 +1988,,,, +1989,241,,, +1990,282,102,1028,180 +1991,300,,301, +1992,304,,870, +1993,292,122,503,170 +1994,211,,352, +1995,174,13,221,161 +1996,283,117,921,166 +1997,272,105,893,167 +1998,239,76,587,163 +1999,285,122,752,163 +2000,276,153,1133,123 +2001,283,115,885,168 +2002,274,116,1087,158 +2003,281,114,613,167 +2004,243,114,803,129 +2005,274,95,945,179 +2006,275,137,1265,138 +2007,247,89,1054,158 +2008,265,118,1128,147 +2009,300,136,690,164 +2010,283,129,928,154 +2011,276,147,740,129 +2012,279,137,762,142 +2013,281,115,1085,166 +2014,254,82,957,172 +2015,278,,693, +2016,268,113,825,155 +2017,303,171,678,132 +2018,302,,930, +2019,,,809,165 +2020,272,,762, +2021,,,, +2022,275,,, +2023,252,,450, +2024,,,, \ No newline at end of file diff --git a/apps/picsa-tools/climate-tool/src/assets/summaries/salima.csv b/apps/picsa-tools/climate-tool/src/assets/summaries/salima.csv index a27405233..240c86f13 100644 --- a/apps/picsa-tools/climate-tool/src/assets/summaries/salima.csv +++ b/apps/picsa-tools/climate-tool/src/assets/summaries/salima.csv @@ -1,71 +1,67 @@ -Year,Rainfall,Start,End,Length -1953,783.9,,258, -1954,1462.1,181,305,124 -1955,1561.3,164,296,132 -1956,1483.8,150,294,144 -1957,1113.6,168,257,89 -1958,1149.2,161,288,127 -1959,1009.2,155,264,109 -1960,1075.2,167,298,131 -1961,1404.9,155,295,140 -1962,1274.6,152,284,132 -1963,1167.8,128,268,140 -1964,1146.6,173,274,101 -1965,862.5,173,297,124 -1966,1144.8,144,289,145 -1967,1421.1,171,288,117 -1968,1467.9,156,288,132 -1969,1114.3,156,289,133 -1970,1575.4,149,282,133 -1971,1285,132,301,169 -1972,907.9,171,287,116 -1973,1603.7,159,301,142 -1974,903.4,159,278,119 -1975,1889.1,158,295,137 -1976,983.4,164,283,119 -1977,2361.5,149,298,149 -1978,1285.2,160,289,129 -1979,1342.2,140,291,151 -1980,1250.2,172,300,128 -1981,781.4,174,295,121 -1982,1090.3,154,281,127 -1983,757.2,162,275,113 -1984,1049.7,162,277,115 -1985,1439.6,157,288,131 -1986,1020.1,155,277,122 -1987,1723.1,158,303,145 -1988,1680.1,158,275,117 -1989,1054.6,153,282,129 -1990,1069.2,162,282,120 -1991,1029.4,135,296,161 -1992,1659.8,165,304,139 -1993,844.7,188,258,70 -1994,452.9,183,266,83 -1995,1027.9,176,297,121 -1996,1227.6,171,282,111 -1997,1685.5,147,282,135 -1998,1163.8,148,268,120 -1999,763.5,194,292,98 -2000,1684.2,122,272,150 -2001,1676,175,266,91 -2002,1460.2,165,278,113 -2003,1106.7,169,293,124 -2004,896.3,148,301,153 -2005,1671,165,280,115 -2006,1366.4,148,291,143 -2007,1261,160,283,123 -2008,759.5,191,276,85 -2009,1205.5,183,299,116 -2010,1084.4,158,264,106 -2011,1141.6,129,286,157 -2012,725.5,141,254,113 -2013,960.8,166,302,136 -2014,701.5,174,275,101 -2015,572.6,171,278,107 -2016,1196.1,159,286,127 -2017,1168.2,150,288,138 -2018,1092.9,159,285,126 -2019,1046.1,149,269,120 -2020,926.1,156,278,122 -2021,1465.5,172,287,115 -2022,0,,, \ No newline at end of file +Year,End,Length,Rainfall,Start +1959,264,,, +1960,298,,1454, +1961,295,140,1404,155 +1962,284,132,1284,152 +1963,268,140,1180,128 +1964,274,102,1153,172 +1965,272,99,788,173 +1966,297,132,809,165 +1967,289,144,1145,145 +1968,288,117,1308,171 +1969,289,133,1114,156 +1970,282,132,1578,150 +1971,301,169,1284,132 +1972,287,116,908,171 +1973,301,142,1603,159 +1974,278,119,902,159 +1975,295,137,1888,158 +1976,283,119,982,164 +1977,298,149,2361,149 +1978,289,129,1284,160 +1979,291,151,1342,140 +1980,271,99,1236,172 +1981,295,121,781,174 +1982,281,127,1089,154 +1983,275,108,743,167 +1984,277,115,1066,162 +1985,288,131,1469,157 +1986,277,122,1039,155 +1987,303,145,1722,158 +1988,275,117,1685,158 +1989,282,129,1054,153 +1990,263,79,1043,184 +1991,296,161,1029,135 +1992,304,141,1392,163 +1993,258,,844, +1994,266,83,451,183 +1995,297,121,1027,176 +1996,282,111,1227,171 +1997,282,135,1685,147 +1998,268,120,1164,148 +1999,292,,763, +2000,272,150,1684,122 +2001,291,116,1559,175 +2002,278,113,1618,165 +2003,293,124,1050,169 +2004,301,153,895,148 +2005,280,115,1671,165 +2006,291,143,1366,148 +2007,283,123,1265,160 +2008,276,136,1236,140 +2009,299,116,1225,183 +2010,264,106,1052,158 +2011,286,102,1116,184 +2012,254,113,718,141 +2013,302,136,985,166 +2014,275,101,699,174 +2015,278,107,572,171 +2016,286,127,1299,159 +2017,288,138,1119,150 +2018,285,126,1093,159 +2019,269,120,1028,149 +2020,278,122,926,156 +2021,287,190,1689,97 +2022,290,,1257, +2023,,,1228, +2024,,,, \ No newline at end of file diff --git a/libs/models/src/climate.models.ts b/libs/models/src/climate.models.ts index 74d6cbcb7..34b81d884 100644 --- a/libs/models/src/climate.models.ts +++ b/libs/models/src/climate.models.ts @@ -17,6 +17,7 @@ export interface IStationMeta { latitude: number; longitude: number; countryCode: string; + district?: string; /** Data summaries for charts */ data?: IStationData[]; /** Definitions for charts */ diff --git a/libs/shared/src/features/data-table/data-table.component.html b/libs/shared/src/features/data-table/data-table.component.html index bf203f505..f76852c2f 100644 --- a/libs/shared/src/features/data-table/data-table.component.html +++ b/libs/shared/src/features/data-table/data-table.component.html @@ -1,7 +1,7 @@
@if(tableOptions.search){ - + Search Data search diff --git a/libs/shared/src/features/data-table/data-table.component.scss b/libs/shared/src/features/data-table/data-table.component.scss index b567db631..44c0532e4 100644 --- a/libs/shared/src/features/data-table/data-table.component.scss +++ b/libs/shared/src/features/data-table/data-table.component.scss @@ -2,7 +2,6 @@ display: block; } .search-field { - margin-top: 2rem; width: 100%; input { text-align: left; diff --git a/libs/shared/src/features/data-table/data-table.component.ts b/libs/shared/src/features/data-table/data-table.component.ts index ed2e87216..855e844ef 100644 --- a/libs/shared/src/features/data-table/data-table.component.ts +++ b/libs/shared/src/features/data-table/data-table.component.ts @@ -15,7 +15,7 @@ import { MatFormFieldModule } from '@angular/material/form-field'; import { MatIconModule } from '@angular/material/icon'; import { MatInputModule } from '@angular/material/input'; import { MatPaginator, MatPaginatorModule } from '@angular/material/paginator'; -import { MatSort, MatSortModule } from '@angular/material/sort'; +import { MatSort, MatSortable, MatSortModule } from '@angular/material/sort'; import { MatTableDataSource, MatTableModule } from '@angular/material/table'; import { capitalise } from '@picsa/utils'; import download from 'downloadjs'; @@ -30,8 +30,8 @@ export interface IDataTableOptions { paginatorSizes?: number[]; /** Specify whether to enable search input box and table filtering (will include all data during filter) */ search?: boolean; - /** Specify whether to include column sort headers (default true) */ - sort?: boolean; + /** Sort settings. Set `false` to disable, or `{ id: 'some_col', start: 'asc' }` to change default sort */ + sort?: boolean | Omit; /** Apply custom formatter to header values. Default replaces underscore with space and capitalises each word */ formatHeader?: (value: string) => string; /** Bind to row click events */ @@ -166,6 +166,10 @@ export class PicsaDataTableComponent implements OnChanges { } // sort will be disabled in html template if not included this.dataSource.sort = this.sort; + // update default sort settings if included + if (this.tableOptions.sort && typeof this.tableOptions.sort === 'object') { + this.dataSource.sort.sort(this.tableOptions.sort as MatSortable); + } this.cdr.markForCheck(); } }