Skip to content

Commit

Permalink
Switch sorting method for new pandas version
Browse files Browse the repository at this point in the history
  • Loading branch information
tsmbland committed Nov 7, 2023
1 parent 5d959a0 commit 9e41976
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/demo/scripts/oxford_demo.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@


dates = input_data.date.unique()
dates.sort()
dates = dates[dates.argsort()]
dates = [pd.Timestamp(x) for x in dates]
print(dates[0:10])
# %% [markdown]
Expand Down
2 changes: 1 addition & 1 deletion wsimod/demo/create_oxford.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ def create_oxford_model(data_folder):
.to_dict()
)
dates = input_data.date.unique()
dates.sort()
dates = dates[dates.argsort()]
dates = [pd.Timestamp(x) for x in dates]
constants.POLLUTANTS = input_data.variable.unique().tolist()
constants.POLLUTANTS.remove("flow")
Expand Down

0 comments on commit 9e41976

Please sign in to comment.