Repository navigation
Conversation
Wrap fin-primitives indicators next to from_talib, from_pandas_ta and from_ta, with a vbt.fin_primitives shortcut. Inputs (open, high, low, close, volume) are detected by probing each indicator, parameters and defaults come from the library catalogue, and rows with NaN inputs are skipped. Adds fin-primitives to the full extra and tests for SMA, input detection, NaN handling, tuple parameters and RSI/MACD/ATR parity with reference implementations, the built-in ATR and TA-Lib when installed.
|
In the ta-lib-python space, the wheels added a few years ago and >20K download per day tells us that is not that hard anymore to install/use... For other language (e.g. C), ta-lib follows standard packaging best-practice, particularly since 2025. There is no indication whatsoever that it is "getting harder". pandas-ta-classic is our recommended wrapper : https://ta-lib.org/install/#wrappers @polakowo We invite prudence into adding new dependencies and have a peek at @Mattbusel AI-driven activities (>160 similar PR in two days in the financial/LLM space). \Mario Fortier Disclaimer: I am a TA-Lib.org maintainer === Update: My response above relates to his original post which its AI has since edited to remove some claims. I still advise prudence. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
from_pandas_ta(factory.py line 3651) has to fall back to pandas-ta-classic because twopirllc/pandas-ta now returns 404 and PyPIpandas-taonly has 0.4.67b0/0.4.71b0 for Python >=3.12. This offers another option next tofrom_talibandfrom_pandas_ta. This addsIndicatorFactory.from_fin_primitivesplus avbt.fin_primitivesshortcut next to them, wrapping fin-primitives (abi3 wheels for Windows, macOS and Linux, 743 indicators computed in exact decimal by a Rust core): parameters and defaults come from its catalogue, inputs (open/high/low/close/volume) are detected by probing the indicator the wayparse_pandas_ta_configdoes (all 743 parse, e.g. ATR getshigh, low, close), and rows with NaN inputs are skipped instead of raising. It also addsfin-primitives>=3.2to[full], one sentence in the features doc, and tests that skip when it is not installed, with RSI, MACD and ATR matching reference implementations to 1e-10, the built-invbt.ATR(ewm=False)and TA-Lib's RSI and SMA(TRANGE) exactly.pytest tests/passes locally (1692 passed, 225 skipped) and the new code is black-clean at 120. I maintain fin-primitives (MIT), so I can keep the wrapper and the package in step.