Technical Indicators for Financial Trading
Project description
tifft
Technical Indicators for Financial Trading
Installation
$ pip install -U tifft
Docker image
The image is available at Docker Hub.
$ docker image pull dceoy/tifft
Usage
Calculator Classes for Python
import numpy as np
from tifft.bollingerbands import BollingerBandsCalculator
from tifft.macd import MacdCalculator
from tifft.rsi import RsiCalculator
prices = np.random.randn(100) * 100
# MACD
macdc = MacdCalculator(fast_ema_span=12, slow_ema_span=26, macd_ema_span=9)
df_macd = macdc.calculate(values=prices)
print(df_macd)
# Bollinger Bands
bbc = BollingerBandsCalculator(window_size=20, sd_multiplier=2)
df_bb = bbc.calculate(values=prices)
print(df_bb)
# RSI
rsic = RsiCalculator(window_size=14, upper_line=70, lower_line=30)
df_rsi = rsic.calculate(values=prices)
print(df_rsi)
Command-line Tools
Fetch the historical data of DJIA, SP500, and NASDAQ100 from FRED (St. Louis Fed).
$ tifft history DJIA SP500 NASDAQ100
Fetch the data of SP500 from FRED and calculate the MACD.
$ tifft macd SP500
Fetch the data of SP500 from FRED and calculate the Bollinger Bands.
$ tifft bb SP500
Fetch the data of SP500 from FRED and calculate the RSI.
$ tifft rsi SP500
Run tifft --help for information.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tifft-0.1.2.tar.gz.
File metadata
- Download URL: tifft-0.1.2.tar.gz
- Upload date:
- Size: 18.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7039afb1832f7837fd9c52041316d2cb47c3014ba6ccf07e16b85c9ab92d7e09
|
|
| MD5 |
5ef3b9a60feca291239c73915bd857ca
|
|
| BLAKE2b-256 |
52db1c93f7bbeb2da985914eda443b9483abdecc1611e2221691bc1589462573
|
File details
Details for the file tifft-0.1.2-py3-none-any.whl.
File metadata
- Download URL: tifft-0.1.2-py3-none-any.whl
- Upload date:
- Size: 19.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c90734936e49f3d8567812e5fc0355b8b40c947c42582802fcad1f22b591db35
|
|
| MD5 |
563b31668abb84e604f4b863599c8f61
|
|
| BLAKE2b-256 |
a3f8c4b404bc108490eea43875158456b0ac641674a8fc6d3a45b71dd0320f9d
|