diff --git a/README.md b/README.md index f0dbfaa..cb349d7 100644 --- a/README.md +++ b/README.md @@ -41,4 +41,31 @@ exits = exits | forced_exits_window exits.tail(20) ``` -`isrising(series,n)`,`isfalling(series, n)` - returns mask where the condition is satisfied of consecutive rising or falling elements \ No newline at end of file +`isrising(series,n)`,`isfalling(series, n)` - returns mask where the condition is satisfied of consecutive rising or falling elements + +## Indicators + +Custom indicators in the `indicators` folder. + +### Importing +```python +from ttools.vbtindicators import register_custom_inds +register_custom_inds(None, "override") #All indicators from the folder are automatically imported and registered. +register_custom_inds("CUVWAP", "override")#just one +``` + +After registration they can be listed and used +```python +vbt.IF.list_indicators("ttools") +vbt.phelp(vbt.indicator("ttools:CUVWAP").run) + +vwap_cum_d = vbt.indicator("ttools:CUVWAP").run(s12_data.high, s12_data.low, s12_data.close, s12_data.volume, anchor=vbt.Default(value="D"), drag=vbt.Default(value=50), hide_default=True) +``` +### Creating + +To create custom indicators CUSTOMNAME.py in `indicators` folder is created containing varibles IND_CUSTOMNAME containing the Indicator Factory class. + +### Available + +- `CUVWAP` - Cumulative VWAP with anchor based on HLCC4 with optional rounding (hlcc4_round, def.3) and drag - warming period from previous anchor unit(def.0). +- `DIVERGENCE` - Various divergences between two timeseries (abs, relative, relative normalized, pct, abs pct) diff --git a/setup.py b/setup.py index 62e5a75..332f7cf 100644 --- a/setup.py +++ b/setup.py @@ -2,7 +2,7 @@ from setuptools import setup, find_packages setup( name='ttools', - version='0.3.2', + version='0.3.3', packages=find_packages(), install_requires=[ 'vectorbtpro',