github-actions[bot] commited on
Commit
46dcbb1
·
1 Parent(s): 96115ef

Deploy from GitHub Actions

Browse files
components.py CHANGED
@@ -279,11 +279,15 @@ def render_correlation_plots(
279
 
280
  def get_reporting_year_info_message(reporting_month: int, example_year: int) -> str:
281
  """Generate standardized info message about reporting year grouping."""
 
 
 
 
282
  return f"""
283
  📅 **Data is grouped by reporting years**:
284
  - Each reporting year ends in **{calendar.month_name[reporting_month]}**. This can be changed in *Settings*.
285
  - Example: Reporting year **{example_year}** covers
286
- **{calendar.month_abbr[(reporting_month + 1) % 12]} {example_year - 1 if reporting_month < 12 else example_year}**
287
  through **{calendar.month_abbr[reporting_month]} {example_year}**.
288
  """
289
 
 
279
 
280
  def get_reporting_year_info_message(reporting_month: int, example_year: int) -> str:
281
  """Generate standardized info message about reporting year grouping."""
282
+ # Calculate start month (if reporting month is November, start month is December of previous year)
283
+ start_month = (reporting_month % 12) + 1
284
+ start_year = example_year - 1 if reporting_month == 12 else example_year
285
+
286
  return f"""
287
  📅 **Data is grouped by reporting years**:
288
  - Each reporting year ends in **{calendar.month_name[reporting_month]}**. This can be changed in *Settings*.
289
  - Example: Reporting year **{example_year}** covers
290
+ **{calendar.month_abbr[start_month]} {start_year}**
291
  through **{calendar.month_abbr[reporting_month]} {example_year}**.
292
  """
293
 
data/master_data_file_2010-01-01_-_2024-11-30.parquet CHANGED
Binary files a/data/master_data_file_2010-01-01_-_2024-11-30.parquet and b/data/master_data_file_2010-01-01_-_2024-11-30.parquet differ
 
main.py CHANGED
@@ -34,6 +34,14 @@ def master_data_csv_to_parquet(file_path: str):
34
  Activity_Start_Date_Time=lambda df: pd.to_datetime(
35
  df["Activity_Start_Date_Time"]
36
  ),
 
 
 
 
 
 
 
 
37
  )
38
  .to_parquet(save_path)
39
  )
 
34
  Activity_Start_Date_Time=lambda df: pd.to_datetime(
35
  df["Activity_Start_Date_Time"]
36
  ),
37
+ Org_Result_Unit=lambda df: df["Org_Result_Unit"].str.replace("none", ""),
38
+ )
39
+ .pipe(
40
+ lambda df: df.assign(
41
+ Sector=df["Sector"].cat.rename_categories(
42
+ {"Fresh Water Lakes": "Freshwater Lakes"}
43
+ )
44
+ )
45
  )
46
  .to_parquet(save_path)
47
  )