Skip to content

Commit e976cd8

Browse files
committed
Fix up doctest
1 parent cd2726d commit e976cd8

File tree

1 file changed

+5
-9
lines changed

1 file changed

+5
-9
lines changed

src/pandas_openscm/unit_conversion.py

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,6 @@ def __init__(self, missing_ts: pd.MultiIndex) -> None:
4242

4343

4444
def convert_unit_from_target_series(
45-
# # TODO: update type hint to pd.Series[supported numerical types here]
46-
# pobj: pd.DataFrame,
4745
pobj: P,
4846
desired_units: pd.Series[str],
4947
unit_level: str = "unit",
@@ -184,8 +182,6 @@ def convert_unit_from_target_series(
184182

185183

186184
def convert_unit(
187-
# # TODO: update type hint to pd.Series[supported numerical types here]
188-
# pobj: pd.DataFrame,
189185
pobj: P,
190186
desired_units: str | Mapping[str, str] | pd.Series[str],
191187
unit_level: str = "unit",
@@ -265,11 +261,11 @@ def convert_unit(
265261
>>>
266262
>>> # Same thing with a series as input
267263
>>> convert_unit(start[2030], "K")
268-
2030
269-
scenario variable unit
270-
sa temperature K 0.002
271-
sb temperature K 1.200
272-
body temperature K 311.250
264+
scenario variable unit
265+
sa temperature K 0.002
266+
sb temperature K 1.200
267+
body temperature K 311.250
268+
Name: 2030, dtype: float64
273269
>>>
274270
>>> # Convert using a mapping.
275271
>>> # Units that aren't specified in the mapping aren't converted.

0 commit comments

Comments
 (0)