Skip to content

Fix EMA calculation for window size 1 - #15474

Closed
GAYATRI7272 wants to merge 5 commits into
TheAlgorithms:masterfrom
GAYATRI7272:fix-ema-window-size-1
Closed

GAYATRI7272 wants to merge 5 commits into
TheAlgorithms:masterfrom
GAYATRI7272:fix-ema-window-size-1

Conversation

@GAYATRI7272

@GAYATRI7272 GAYATRI7272 commented Oct 1, 2026 •

Copy link
Copy Markdown

Fixes #15449

Describe your change

  • Fix a bug or typo in an existing algorithm?
  • Add or change doctests?
  • Add an algorithm?
  • Documentation change?

Checklist

  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized.
  • I know that pull requests will not be merged if they fail the automated tests.
  • This PR only changes one algorithm file.
  • All functions and variable names follow Python naming conventions.
  • All functions have doctests that pass the automated testing.

@algorithms-keeper algorithms-keeper Bot added awaiting reviews This PR is ready to be reviewed enhancement This PR modified some existing files tests are failing Do not merge until tests pass and removed tests are failing Do not merge until tests pass labels Oct 1, 2026
@GAYATRI7272

Copy link
Copy Markdown
Author

pre-commit.ci autofix

@algorithms-keeper algorithms-keeper Bot removed the tests are failing Do not merge until tests pass label Oct 1, 2026
@GAYATRI7272
GAYATRI7272 force-pushed the fix-ema-window-size-1 branch from 804bb06 to 85bfc12 Compare October 1, 2026 09:43
@algorithms-keeper algorithms-keeper Bot added tests are failing Do not merge until tests pass labels Oct 1, 2026
@GAYATRI7272

Copy link
Copy Markdown
Author

The Ruff check is currently failing on two pre-existing E501 errors in ciphers/des_ecb.py (lines 547 and 554). My PR diff only contains financial/exponential_moving_average.py.

@GAYATRI7272

Copy link
Copy Markdown
Author

pre-commit.ci autofix

@algorithms-keeper algorithms-keeper Bot removed the tests are failing Do not merge until tests pass label Oct 1, 2026
@cclauss cclauss closed this Oct 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting reviews This PR is ready to be reviewed enhancement This PR modified some existing files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

exponential_moving_average returns an incorrect second value when window_size=1

2 participants