Spaces:
Sleeping
Sleeping
File size: 205 Bytes
8e0b458 |
1 2 3 4 5 6 7 8 9 |
# indicators/sma.py
import pandas as pd
def ema(df, period=20, column="Close"):
"""
Calculates Exponential Moving Average (EMA)
"""
return df[column].ewm(span=period, adjust=False).mean() |