Comments (9)
Hi @twopirllc, this sounds interesting I'll have a look!
from pyjuque.
Definitely not an overkill, really thanks for the detailed explanation. It
put me at ease with respect to the speed of calculation / perceived
bottleneck as I haven't tested their speed myself.
Cool.
So rewriting some of them in a recursive fashion to compute 'in real time' - at least for the indicators that it is possible - might be a use case for python
Yeah.
I imagine that a well thought out algorithm can perform without issues in
the current scenario, with a small number of pairs - however you're right,
if you want to compute hundreds of indicators on dozens of pairs every
minute
Right. I am also building out a Watchlist Class that manages a group of tickers and fetches data from AlphaVantage (currently), and processes TA assigned to it. It's a work in progress with the goal to add more data sources, brokers, and an event loop for live or simulation.
Again thanks for this answer and your effort of converting TA-lib to python
- I am almost certainly using this library for pyjuque as I wanted to
change pyti for a long time - I might even give it a try to update some
indicators to real-time!
Thanks! Yeah, TA Lib also does not easily install some systems. So I made Pandas TA to have the same level of accuracy as TA Lib, ease of use, and compatibility with the Python Data Science / ML / FinTech ecosystem. I have other cool features in mind to add. I just need to make time to program them. Looking forward to what you produce.
Thanks,
KJ
from pyjuque.
If you have any questions, let me know.
KJ
from pyjuque.
Definitely - just had a thought, wanted to see your take on it... you know with real time trading sometimes you want to compute an indicator value only for the last Candle for example - because you already computed it for the previous ones. How many indicators in your library would have that capability, or should most of them be rewritten to allow for that? (I imagine a lot of devs would like to have this ability in a TA library..)
from pyjuque.
Excellent question.
I imagine a lot of devs would like to have this ability in a TA library..
No doubt!
Yet, in my experience of both creating indicators and reverse engineering them from TA Lib, Trading View, et al, it is not possible for many indicators.
In fact it was a discussion on my repo as well. It's the first Pinned Issue: How to utilize this Framework for live ticks #87. Unfortunately, I haven't had much chance to personally address this issue more. Hopefully soon! 🤞
Brokers, Charting Software, and Web Platforms
Traditional Broker Platforms like Trade Station, Think or Swim, Interactive Brokers as well as specialty charting platforms like MultiCharts, Sierra Charts et al are a mix of C, C++, C#, and Java typically. I have not found anything online yet on how any of them do it, but it's unlikely a concern considering their choice of language.
For the web trading platform Trading View, this is how they handle the Execution of Pine Script
Requirements or Limitations
I suppose it really depends on your requirements or limitations.
If the requirement is truly HFT, microseconds trading with a dedicated machine as close to the exchange as possible, then Python is obviously not the choice. However if it is tick data, then you should be fine in many cases with performant hardware. Lastly for 1 minute and higher time frames, I wouldn't be concerned.
For instance, I am running a 2013 Mac Book Pro with 4G RAM, 4 Cores. When using Pandas TA, I can process over a hundred different indicators in about 4secs with ohlcv data containing 700 rows. However in reality, one would have a small sample of indicators to use and it takes my machine microseconds.
For example, when I used this subset of indicators (max period of 200) with 700 bars I got around 50 ms (or 0.05 secs) to process them. When I take 210 bars, 10 extra bars for buffer, I get around 30 ms (or 0.03 secs). Even with my hardware limitation, TA speed bottlenecks are trivial.
But if you have a small portfolio to live track and calculate as a scanner list, of course it may take marginally longer to process them in a blocking manner.
How many indicators in your library would have that capability, or should most of them be rewritten to allow for that?
So in my opinion, I don't think it is necessary to rewrite the few that may benefit. Even with older hardware, TA is pretty fast.
Apologies if this was overkill...
KJ
from pyjuque.
from pyjuque.
hi all nice guy!
do you know this project?
https://github.com/freqtrade/freqtrade
Maybe you can take some ispiration from.
from pyjuque.
another interesting source is 👍
https://towardsdatascience.com/how-to-create-a-fully-automated-ai-based-trading-system-with-python-708503c1a907
https://www.freqtrade.io/en/latest/strategy-customization/
https://github.com/ccxt/ccxt
https://www.shrimpy.io/demo
from pyjuque.
from pyjuque.
Related Issues (20)
- Grid Bot - Margin HOT 1
- InvalidRequestError: One or more mappers failed to initialize - can't proceed with initialization of other mappers. HOT 5
- TypeError(“'<' not supported between instances of 'numpy.ndarray' and 'str'”) HOT 2
- error on tryExitOrder; cannot place limit order after buy fill due to balance error HOT 4
- <class 'ccxt.base.errors.Order Not Found'> in updateOpenOrder() HOT 7
- How to
- Get Bot Started HOT 4
- Error executing examples/try_order_management.py in feature branch / order_management HOT 1
- TypeError When setting `entry_settings` -> `signal_distance` = 0
- i have the bot running in pycharm, but its not placing order on binance us order book. ive watched your recent tuts and seen that this bot can go on multpy exchanges.
- Cannot trade symbol without '/' in the name HOT 1
- open_buy_order_time_out HOT 1
- okex exchange didn't work HOT 1
- Faulty creation of client_id HOT 1
- Bot does not stop with Ctrl+C? HOT 7
- Symbol in DB but not bot_config HOT 2
- Balance & Selling manually caused pyjuque notification messages non-stop HOT 2
- NULL value in match_order_id
- InsufficientFunds error placing Sell order despite enough Binance balance HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyjuque.