Skip to content

Commit 0cde301

Browse files
authored
Update simple_moving_average.py
Changes have been applied.
1 parent e2c5795 commit 0cde301

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

financial/simple_moving_average.py

+2-4
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,8 @@ def simple_moving_average(
3535
raise ValueError("Window size must be a positive integer")
3636

3737
if window_size > len(data):
38-
raise ValueError(
39-
"Window size must be smaller than the total length of the time series"
40-
)
41-
38+
raise ValueError("Window size must be smaller than the total length of the time series")
39+
4240
sma: list[float | None] = []
4341

4442
for i in range(len(data)):

0 commit comments

Comments
 (0)