Skip to content

Commit

Permalink
Relax min periods for standard deviation
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiasmarke committed Aug 21, 2024
1 parent 413ca88 commit d0c87ef
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion mwrpy/atmos.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ def find_lwcl_free(lev1: dict) -> tuple[np.ndarray, np.ndarray]:
ind = utils.time_to_datetime_index(lev1["time"][:])
tb_df = pd.DataFrame({"Tb": tb}, index=ind)
tb_std = tb_df.rolling(
pd.tseries.frequencies.to_offset("2min"), center=True, min_periods=60
pd.tseries.frequencies.to_offset("2min"), center=True, min_periods=40
).std()
tb_mx = tb_std.rolling(
pd.tseries.frequencies.to_offset("20min"), center=True, min_periods=100
Expand Down
2 changes: 1 addition & 1 deletion mwrpy/level2/lwp_offset.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def correct_lwp_offset(
lwp[elevation_angle[index] < 89.0] = np.nan
lwp_df = pd.DataFrame({"Lwp": lwp}, index=ind)
lwp_std = lwp_df.rolling(
pd.tseries.frequencies.to_offset("2min"), center=True, min_periods=60
pd.tseries.frequencies.to_offset("2min"), center=True, min_periods=40
).std()
lwp_max = lwp_std.rolling(
pd.tseries.frequencies.to_offset("20min"), center=True, min_periods=100
Expand Down

0 comments on commit d0c87ef

Please sign in to comment.