Skip to content

Commit

Permalink
Remove capital letters from TC_days and ACE
Browse files Browse the repository at this point in the history
  • Loading branch information
stella-bourdin committed Oct 14, 2024
1 parent d7773ab commit 47f29ae
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions huracanpy/diags/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@
"time_from_extremum",
"rate",
"freq",
"TC_days",
"ACE",
"tc_days",
"ace",
]

from ._track_density import simple_global_histogram
from ._track_stats import duration, gen_vals, extremum_vals, ace_by_track, pace_by_track
from ._lifecycle import time_from_genesis, time_from_extremum
from ._rates import rate
from ._climato import freq, TC_days, ACE
from ._climato import freq, tc_days, ace
6 changes: 3 additions & 3 deletions huracanpy/diags/_climato.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def freq(self, by=None, track_id_name="track_id"):
return self.groupby(by).apply(freq, by=None).mean()


def TC_days(self, by=None, track_id_name="track_id", time_name="time"):
def tc_days(self, by=None, track_id_name="track_id", time_name="time"):
"""
Function to compute the number of "TC days", or cumulated TC duration, potentially normalized by another variable (e.g. season to get yearly TCD).
Expand All @@ -68,10 +68,10 @@ def TC_days(self, by=None, track_id_name="track_id", time_name="time"):
if by is None:
return xr.DataArray(duration(self[time_name], self[track_id_name]).sum() / 24)
else:
return self.groupby(by).apply(TC_days, by=None).mean()
return self.groupby(by).apply(tc_days, by=None).mean()


def ACE(
def ace(
self, by=None, wind_name="wind", threshold=0 * units("knots"), wind_units="m s-1"
):
"""
Expand Down

0 comments on commit 47f29ae

Please sign in to comment.