demandlib icon indicating copy to clipboard operation
demandlib copied to clipboard

Fix FutureWarnings

Open maurerle opened this issue 2 years ago • 0 comments

To Reproduce The following snippet produces warnings using python 3.11 and pandas 2.2.1

from demandlib.bdew import ElecSlp
e_slp = ElecSlp(2019)

demandlib had some pandas warnings:

  • FutureWarning: Downcasting object dtype arrays on .fillna, .ffill, .bfill is deprecated and will change in a future version
  • FutureWarning: Setting an item of incompatible dtype is deprecated and will raise in a future error of pandas
  • FutureWarning: A value is trying to be set on a copy of a DataFrame or Series through chained assignment using an inplace method

These are fixed through this commit.

maurerle avatar Apr 15 '24 08:04 maurerle