Skip to content

Commit 400ed99

Browse files
committed
Adapt code to new pandas warnings
1 parent 09c9867 commit 400ed99

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

example/modelchain_example.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,9 +130,9 @@
130130
" 'Europe/Berlin')\n",
131131
" # change type of height from str to int by resetting columns\n",
132132
" weather_df.columns = [weather_df.axes[1].levels[0][\n",
133-
" weather_df.axes[1].labels[0]],\n",
133+
" weather_df.axes[1].codes[0]],\n",
134134
" weather_df.axes[1].levels[1][\n",
135-
" weather_df.axes[1].labels[1]].astype(int)]\n",
135+
" weather_df.axes[1].codes[1]].astype(int)]\n",
136136
" return weather_df\n",
137137
"\n",
138138
"\n",

example/modelchain_example.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,9 +80,9 @@ def get_weather_data(filename='weather.csv', **kwargs):
8080
'Europe/Berlin')
8181
# change type of height from str to int by resetting columns
8282
weather_df.columns = [weather_df.axes[1].levels[0][
83-
weather_df.axes[1].labels[0]],
83+
weather_df.axes[1].codes[0]],
8484
weather_df.axes[1].levels[1][
85-
weather_df.axes[1].labels[1]].astype(int)]
85+
weather_df.axes[1].codes[1]].astype(int)]
8686
return weather_df
8787

8888

0 commit comments

Comments
 (0)