Skip to content

Commit

Permalink
fix join
Browse files Browse the repository at this point in the history
  • Loading branch information
trevorb1 committed Nov 27, 2024
1 parent e136e1a commit 8336338
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions workflow/scripts/osemosys_global/validation/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ def _join_data(

modelled = modelled.rename(columns={"VALUE": "OSeMOSYS"})
actual = actual.rename(columns={"VALUE": dataset_name})
df = modelled.join(actual, how="inner")

df = modelled.join(actual, how="left").fillna(0)

index_values = [df.index.get_level_values(x).unique() for x in df.index.names]
idx = pd.MultiIndex.from_product(index_values, names=df.index.names)
df = df.reindex(idx, fill_value=0)
Expand Down

0 comments on commit 8336338

Please sign in to comment.