Library for calculating diverse financial metrics
Project description
Technicators
Technicators provides a collection of methods for calculating various technical indicators commonly used in financial analysis.
Installation
pip install technicators
Usage
import pandas as pd
from technicators import Technicators
# Sample time series data
data = pd.Series([...])
# Calculate ALMA
alma_values = Technicators.ALMA(data, period=14)
# Calculate EMA
ema_values = Technicators.EMA(data, period=14)
# Calculate HMA
hma_values = Technicators.HMA(data, period=14)
# Calculate SMMA
smma_values = Technicators.SMMA(data, period=14)
# Calculate TEMA
tema_values = Technicators.TEMA(data, period=14)
# Calculate WMA
wma_values = Technicators.WMA(data, period=14)
Method Details
ALMA
- Calculates the Arnaud Legoux Moving Average (ALMA) using a variable window.
- Parameters:
dataset
(pd.Series): The input time series data.period
(int): The period over which to calculate the ALMA.offset
(float): Offset multiplier for ALMA calculation. Default is 0.85.sigma
(float): Standard deviation factor for ALMA calculation. Default is 6.
- Returns:
pd.Series
: A time series representing the ALMA values.
EMA
- Calculates the Exponential Moving Average (EMA) of a given time series.
- Parameters:
dataset
(pd.Series): The input time series data.period
(int): The period over which to calculate the EMA.adjust
(bool): Whether to adjust the EMA calculation. Default is True.
- Returns:
pd.Series
: A time series representing the EMA values.
HMA
- Calculates the Hull Moving Average (HMA) using weighted moving averages.
- Parameters:
dataset
(pd.Series): The input time series data.period
(int): The period over which to calculate the HMA.
- Returns:
pd.Series
: A time series representing the HMA values.
SMMA
- Calculates the Smoothed Moving Average (SMMA) using exponential smoothing.
- Parameters:
dataset
(pd.Series): The input time series data.period
(int): The period over which to calculate the SMMA.adjust
(bool): Whether to adjust the SMMA calculation. Default is True.
- Returns:
pd.Series
: A time series representing the SMMA values.
TEMA
- Calculates the Triple Exponential Moving Average (TEMA) using triple exponential smoothing.
- Parameters:
dataset
(pd.Series): The input time series data.period
(int): The period over which to calculate the TEMA.adjust
(bool): Whether to adjust the TEMA calculation. Default is True.
- Returns:
pd.Series
: A time series representing the TEMA values.
WMA
- Calculates the Weighted Moving Average (WMA) using weighted averages.
- Parameters:
dataset
(pd.Series): The input time series data.period
(int): The period over which to calculate the WMA.
- Returns:
pd.Series
: A time series representing the WMA values.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
technicators-1.0.0.tar.gz
(3.7 kB
view hashes)
Built Distribution
Close
Hashes for technicators-1.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 30c9c7a500aefe1ef42f353bb25be963ae54570472dcdffedf0b66a6ae4a3a39 |
|
MD5 | f57a1d2e6e3c5680fe4ac0183585fde5 |
|
BLAKE2b-256 | dcab55157eaa3719eb6f033cbbca8e66b5f1db92ab22ff19aabc99d5d6210d68 |