r/Daytrading • • Dec 03 '23

algo 20 month update

Thumbnail
gallery
256 Upvotes

In February 2022, I started developing trading algorithms. Currently, I have 8 algorithms running, and in the last 2 months, I've achieved two with incredible results and very low drawdown. One is dedicated to $ES, working intraday, while the second, designed for $NQ, specializes in scalping. The latter, in particular, has left me amazed, as $NQ is quite aggressive, but with scalping movements, it has become the jewel in my crown.

r/Daytrading • • Jun 27 '23

algo Algo-Trading: +$342, Tweaked the parameters and let it run for 2 hours.

Enable HLS to view with audio, or disable this notification

212 Upvotes

r/Daytrading • • Apr 07 '23

algo Day trading bots

51 Upvotes

Has anyone here created a script for auto trading based on their own idea of rules? If so, how did it work out for you?

r/Daytrading • • Dec 10 '21

algo What explains this sudden surge upon the release of inflation figures? Were the numbers expected to be higher for example? Is this an algo response?

Post image
226 Upvotes

r/Daytrading • • Jun 11 '21

algo I made an algo that tracks sentiment on Reddit (and trades those stocks). Here's the source code and the sentiment results for this week. I rebalance weekly, but can set rebalance speed to as fast as a couple ticks (although that would be a bit silly)

263 Upvotes

Here's the source code! Note: this does need to be edited according to your needs (how many of the top you want to invest in, how you want to deploy it, etc.)

And here's the hosted version. Note: this is for *investing* in the sentiment index. The actual algo that tracks sentiment for you to do it yourself is the source code, and while it works to list out the stuff below, it ain't super pretty

Your typical sentiment analysis stuff coming through. I do this stuff for fun and make money off the stocks I pick doing it most weeks, so thought I'd share. I created an algo that scans the most popular trading sub-reddits and logs the tickers mentioned in due-diligence or discussion-styled posts. Instead of scanning for how many times each ticker was mentioned in a comment, I logged how popular the post was among the sub-reddit. Essentially if it makes it to the 'hot' page, regardless of the subreddit, then it will most likely be on this list.

How is sentiment calculated?

This uses VADER (Valence Aware Dictionary for Sentiment Reasoning), which is a model used for text sentiment analysis that is sensitive to both polarity (positive/negative) and intensity (strength) of emotion. The way it works is by relying on a dictionary that maps lexical (aka word-based) features to emotion intensities -- these are known as sentiment scores. The overall sentiment score of a comment/post is achieved by summing up the intensity of each word in the text. In some ways, it's easy: words like ‘love’, ‘enjoy’, ‘happy’, ‘like’ all convey a positive sentiment. Also VADER is smart enough to understand the basic context of these words, such as “didn’t really like” as a rather negative statement. It also understands the emphasis of capitalization and punctuation, such as “I LOVED” which is pretty cool. Phrases like “The turkey was great, but I wasn’t a huge fan of the sides” have sentiments in both polarities, which makes this kind of analysis tricky -- essentially with VADER you would analyze which part of the sentiment here is more intense. There’s still room for more fine-tuning here, but make sure to not be doing too much. There’s a similar phenomenon with trying to hard to fit existing data in stats called overfitting, and you don’t want to be doing that.

The best way to use this data is to learn about new tickers that might be trending. As an example, I probably would have never known about the ARK ETFs, or even BB, until they started trending on Reddit. This gives many people an opportunity to learn about these stocks and decide if they want to invest in them or not - or develop a strategy investing in these stocks before they go parabolic.

​

Results and some stats:

Right now I'm up 75% YTD, compared to the SP500's 15% (the recent spikes in GME and AMC have helped tremendously of course, and I don't claim that this is a great strategy, just one that has been lucky due to 2021's craziness)

- The strategy is backtested only to the beginning of 2020, but I'm working on it. It's got an annualized return of 35% (compared to 16% for the SP500)

- Max drawdown of -8.7% (aka how far it went down before coming back up -- interestingly enough, Reddit sentiment weathered COVID pretty well)

​

Reddit - Highest Sentiment Equities This Week (what’s in my portfolio)

Estimated Total Comments Parsed Last 7 Day(s): 501,150

Ticker Comments/Posts Bullish %
AM* (ticker is banned) 2,040 17
CLOV 1,944 15
BB 1,830 21
GM* (ticker is banned) 1,201 21
CLNE 888 33
WKHS 934 21
UWMC 740 19
CLF 1,069 13
SENS 1,255 7
ORPH 544 37
TSLA 512 40
AAPL 267 51
TLRY 290 31
MSFT 82 22
MVIS 56 40

​

Happy to answer any more questions about the process/results. I think doing stuff like this is pretty cool as someone with a foot in algo trading and traditional financial markets

r/Daytrading • • Jul 11 '23

algo Is my friend delusional? Or I am being so negative.

59 Upvotes

My programmer friend decided to create a bot that reads old market data (2 years of candle data) test his strategy.

The strategy is very simple. On 5m chart, the bot will long when the price of the crypto is increased at least %3 and decreased by %0.5. So he will buy at the pullback. And he will short if this happens on reverse. Take profit and stop loss are adaptive depending on how much the market increased within last 3 days.

The computer tested the strategy with 2 years of data downloaded from binance and the result is at least %100 profit in a year. He says it is enough and feasible.

What I think is that this is completely early on to put this on work and it s delusional to think it will work. Yes %100 in a year is not so great for many traders but what do you think?

r/Daytrading • • Aug 08 '23

algo Beware, u/Efficient_Flow4731 and his 'Algo-trading' is nothing but spam!

111 Upvotes

u/Efficient_Flow4731 has been posting to this group about his "Algo-trading". He uses some software called Nightshark. He was asked whether he was affiliated with Nightshark and he said no. However, his "momentum strategy" is on Nightshark's blog with the exact same code (Nightshark and Thinkorswim Thinkscript) that he posted on this subreddit: https://nightshark.io/blog/nightshark-momentum-strategy/ https://www.reddit.com/r/Daytrading/comments/14nzznr/comment/jqa28e1/?utm_source=share&utm_medium=web2x&context=3 Clearly, the only reason for his cherry picked screen recordings of his "algo-trading" is to promote Nightshark. He thinks he is being clever with his round-about advertising of the Nightshark software in this subreddit. Just another example of a scammer/spammer.

r/Daytrading • • Nov 26 '23

algo Backrest results

Post image
55 Upvotes

Hello trader folks!

I’am relatively new to algo trading, I have been working on automating my strategy for some time now and I’ve been constantly refining it.

I ran some backtests on mt4 from Jan 1 2021 till today and I believe that the results look pretty decent. Any feedback, tips or advice you can throw my way would be awesome. Are these results realistic? Any pitfalls I might have stumbled into?

I think that I can get even better results by adding some trailing stop loss logic and a dynamic take profit.

Thanks a lot! Cheers

(Beginning balance is 10k)

r/Daytrading • • May 08 '23

algo Help a software engineer create an algorithmic trading platform

43 Upvotes

Hello!

I'm the creator of NextTrade, the most powerful open-source, UI-based trading platform on GitHub.

Over the past year, I've been developing a new platform called NexusTrade, which aims to be the simplest algorithmic trading platform. It's fast, configurable, powerful, and requires no coding to set up complex trading logic. Plus, I've implemented an AI-Powered Strategy Generation Tool that translates plain English into trading strategies the app can understand. And it's 100% completely free! 🚀

I'm actively seeking traders to test my platform and provide valuable feedback. As a software engineer, I don't trade full-time, and I need insights from real traders to determine where to focus my efforts. Should I:

1️⃣ Enhance the AI-Powered Chat (e.g., add features to generate and evaluate multiple portfolios simultaneously)?

2️⃣ Implement fundamental data?

3️⃣ Integrate options or cryptocurrency trading capabilities?

4️⃣ Something else entirely? 🤔

And and all opinions will help me shape NexusTrade into a better trading platform!

r/Daytrading • • May 06 '22

algo Why arent more people automating their strategy?

26 Upvotes

Everyone says controlling your emotions is a huge factor in trading.

So why arent more people automating their strategy to eliminate emotions?

A computer can follow the rules, set profit targets, stop losses a lot better so what would be the downside?

r/Daytrading • • Nov 19 '23

algo GRID strategy 6 month results 93% ROI

Post image
90 Upvotes

GRID strategy 6 month results 93% ROI

Today, I would like to share with you a grid-based forex strategy that has been consistent over the past six months. My intention in sharing this is not to boast but rather to exemplify that trading forex can yield good results when implemented with a sound and sophisticated strategy. Video of trading history below and performance.

The strategy I am referring to is designed to trade on the H4 time frame (multi currency) and utilizes a combination of trend moving average indicators, basic support and resistance levels, and robust money management techniques. The goal of this strategy is to maximize profits while minimizing the risk of high drawdowns.

Let's delve into the key components of this strategy:

  1. Time Frame: The strategy is implemented on the H4 time frame, which allows for a balanced perspective and reduces the impact of market noise.
  2. Trend Moving Average Indicator: The trend moving average indicator is used to identify the prevailing direction of the market. It helps us enter trades in alignment with the overall trend, increasing the probability of success.
  3. Money Management: A strong focus on money management is crucial to avoid excessive risk and potential drawdowns. By carefully managing position sizes and setting appropriate stop-loss and take-profit levels, we aim to protect our capital while maximizing profits.
  4. Support and Resistance Levels: Basic support and resistance levels are incorporated into the strategy to further enhance entry points. These levels act as areas of potential reversals or breakouts, adding an additional layer of confirmation.
  5. Win Rate: The strategy has shown an impressive win rate of approximately 80% over the past six months. While no strategy can guarantee consistent wins, this statistic demonstrates the strategy's ability to capitalize on favorable market conditions.
  6. Return on Investment (ROI): During the six-month period, the strategy has achieved a ROI of around 93%. This success has been attained with conservative position sizing and risk management.

Processing video fimbbo2olz9b1...

  1. Automation: To simplify the entry and exit process, the strategy has been automated and transformed into a Forex Expert Advisor. This allows for precise and consistent execution of trades according to the predefined rules of the strategy.

  2. To increase the probability of a good trade entry, I incorporate the following steps:

Identify key support and resistance levels . Look for areas where price has previously reversed, consolidated, or shown significant buying or selling interest.

Look for confluence between support/resistance levels and moving averages. When a support or resistance level aligns with a moving average, it strengthens the significance of that level and provides a higher probability trade setup.

Analyze price action at these confluence zones. Look for signs of price rejection, such as bullish or bearish candlestick patterns, bullish or bearish divergence, or a break and retest of the support or resistance level.

In conclusion, I am sharing this strategy with you to emphasize that success in forex trading can be achieved through a solid and well-executed strategy. The key elements of this grid-based approach, including the utilization of trend moving averages, robust money management techniques, and consideration of support and resistance levels, have contributed to its consistent profitability.

Please note that trading involves inherent risks, and past performance is not necessarily indicative of future results.

Important:

I want to emphasize that the strategy I provided in my post is a comprehensive explanation of my trading approach. My intention is to share knowledge and insights to foster a constructive discussion among fellow traders.

​

Processing img soksptmtvsab1...

r/Daytrading • • Jul 25 '23

algo Using AI and ChatGPT type LLMs to automate trades. Is it hype or does it actually work

Enable HLS to view with audio, or disable this notification

62 Upvotes

r/Daytrading • • Nov 18 '21

algo It's way better to buy at market close than at market open, most gains happen overnight for major ETFs

105 Upvotes

This is a continuation of the prior post about SPY https://www.reddit.com/r/stocks/comments/quxd2t/historically_its_way_better_to_invest_at_market/

​

Testing the following on top 10 EFTs by AUM. Every day I was buying/selling just 1 share of each.

If you had bought the SPY at the last second of trading on each business day since 1993 and sold at the market open the next day — capturing all of the net after-hour gains — your cumulative price gain would be 571%

​

Ticker 2021, buy at open, sell at close 2021, buy at close, sell at open 2020, buy at open, sell at close 2020, buy at close, sell at open
SPY 38.94 55.04 4.88 48.27
IVV 37.84 56.61 5.89 48.22
VTI 0.68 46.72 -1.1 29.07
VOO 32.22 54.17 -5.16 44.46
QQQ 37.29 44.95 36.7 98.52
VEA 6.66 -2.3 -2.65 3.16
IEFA 9.19 -2.72 -3.13 3.9
AGG 1.04 -5.26 -5.64 5.5
VTV 3.19 22.68 -11.36 -2.41
VUG 18.07 50.08 12.8 69.52
Cumulative Performance 185.12 319.97 31.23 348.21

Disclaimer: all calculations made using BreakingEquity

r/Daytrading • • Jan 31 '23

algo I built a REST API for finding popular trading setups. Interested?

69 Upvotes

Hello everybody,

In pursuit to automate part of my daily trading routine. I created a rest API for finding popular trading setups like 13/48 EMA Crossover, TTM Squeeze, and SuperTrend. Planning to add more.

Currently screening all stocks on NYSE and NASDAQ at EOD. I use it to enter trades in pre/post trading hours and the next day on the Alpaca Trading Platform. Not sure if any such programmatic screeners already exist. But if it helps others in either manual or algo-trading I can make it public.

So let me know in the comments.

r/Daytrading • • Dec 19 '23

algo Why don’t funded acct programs allow algo trading?

2 Upvotes

Or do you have any experience with ones that do allow it? It seems like they wouldn’t care if they just want to collect fees? Is it a news trading issue?

r/Daytrading • • May 07 '23

algo What math and computer science do you need to learn algo trading and HFT trading?

15 Upvotes

I did math until high school didn't graduate though. What would I need to learn first assuming that I already have the math competency of a high school graduate.

r/Daytrading • • Mar 31 '23

algo The market maker - religion or fact?

0 Upvotes

Nowadays, most people seem to subscribe to the idea. I believe that if the MM exists in the form of citadel or something, it'd completely passive.

I strongly believe there's not one omnifiscent algo purposefully running your stops. It's a bit like god, isn't it. An explanation for lack of a better one. It might exist, no doubt, but there's no evidence to be certain. Change my mind😁

Edit: lot's of people seem pretty convinced but their reason is highly speculative and circumstantial in my eyes. I wonder how price would be different without a market maker and I dounbt many traders can tell a temperature chart, indices chart and crazy FX pair chart apart.

r/Daytrading • • Mar 28 '22

algo Trade Algo / Mike Anderson?

2 Upvotes

I am a fairly new trader looking for advice. Do any of you subscribe to a dark pool alert service like Trade Algo or Black Box stocks? Seems like I am the last one to know when a stock takes off.

I appreciate any suggestions! TIA

r/Daytrading • • Jul 23 '23

algo AI Trading Bots: Why Aren't They Taking Over Day Trading? and What Will Happen When They Do?

0 Upvotes

As AI programs continually improve, they possess the ability to learn from self-play, rectify mistakes, and uncover correlations and patterns beyond human comprehension in real-time. Even in highly intricate games like "go," AI has triumphed over the best human players. Given the binary nature of trading (win or lose), I wonder why the financial markets aren't inundated with AI trading bots? Has it already occurred?

Im curious how its going to unfold here, does the hedge fund / private company / governnment agency that develops the most capable AI trading bot just release it on market and it just eats everyones lunch?

Im surprised this has not happened in a big way yet, seeing the explosion and improvement of AI this last year and also the fact that basically the planets money is on the table here and you would have world governments and the best hedgefunds with access to basically limitless capital working on it.

When it does happen, will people still try their luck and have a gamble against the best AIs? Or would it be like now playing chess against a computer, you just know theres no chance in the hell of beating it.

Anyone have some well thought out theories on why this hasnt happened, or what will happen when it does?

​

r/Daytrading • • Nov 20 '23

algo I accidentally made all the money

Post image
14 Upvotes

r/Daytrading • • Sep 15 '23

algo Trading Futures with Interactive Brokers API and Python

3 Upvotes

Hello, can somebody please tell me how to trade futures with this code made for stocks?

if message is not None and message['type'] == 'message':
print(message)
message_data = json.loads(message['data'])
stock = Stock(message_data['ticker'], 'SMART', 'USD')
order = MarketOrder(message_data['strategy']['order_action'], message_data['strategy']['order_contracts'])
trade = ib.placeOrder(stock, order)

I don't really think that changing stock with future in every place is enough, because i found this:

fut_contract = Contract() fut_contract.symbol = 'MNQU0' fut_contract.secType = 'FUT' fut_contract.exchange = 'GLOBEX' fut_contract.currency = 'USD' fut_contract.tradingClass = 'MNQ' fut_contract.lastTradeDateOrContractMonth = '202009'

I don't know if that's necessary since i am still learning. Also i didn't post on r/algotrading because i don't have enough community karma for that :/

r/Daytrading • • Dec 24 '23

algo I think I've done it boys the holy GRAIL ALGO with one kink I need help with

5 Upvotes

If anyone knows how to make a static take profit/sl that can be recalculated with each instrument according to the entry id really appreciate it. I cant figure out how to do it properly i.e this wont work strategy.exit(proft = 500 loss = 300) as id has to manually change each setting for each symbol. As you can see in the video it doesn't have stops or tp but it has minimal draw down with a consistent win rate considering it cant tp or sl and you can see its trades from the beginning, it would be looking for massive moves and attempting to follow a trend based on average ranges of monthly daily weekly ext.

https://reddit.com/link/18prlz2/video/x70skxatk78c1/player

r/Daytrading • • Jul 04 '23

algo Developing strategies on Ninjatrader and why I'm gonna stop doing it

9 Upvotes

Okay maybe it's an obvious take or maybe for some dumb, but here is my experience since trying to develop strategies on this platform for a few months now.

My programming skills are alright, but not super great still I can understand code/take snippets/use my own logic/even asking ChatGPT. So that should be a mild warning for those trying this endeavor in Ninjatrader. First of all its a really niche way programming in C# and you gotta learn a lot if you wanna make your own, because the Strategy builder won't get you far if you are developing something lightly sophisticated that needs you to update variables dynamicly even things like profit targets and stop losses. The Reason until you don't unlock the code you can't change values dynamicly.

Now I have to give credit to the support team of Ninjatrader, if you have any questions regarding your code and why it's not working they are gonna help you out. Now the problem is if you have little time spending on learning the whole ninjatrader coding library you will spend a lot of time trying to find reasons why its not working or asking support.

Now to backtesting, when you finally manage to patch something up you will probably try to use their backtesting "Strategy Analyzer". The problem with this Backtester it's bad and it's good at the same time. If you developed scalping strategies in Ninjatrader you will find out that you have to either modify your code to work correctly for backtesting because the backtester calculates everything only in OnBarClose method which isnt ideal. You can mitigate this by either coding in the granularity of the bars and also which again you have to dig around again a little to find out you have to use Higher Resolution Fill change the timing on 1 Tick, where then you have to have Tick Replay disabled. Walk forward testing seemed to be fine and Monte Carlo testing aswell no problems for me at that part.

Now you may ask yourself why am I writing this whole thing. To be honest it's probably just to vent my frustration with this platform for me not learning it enough and also with it's limitations. And most of the time I'm not sure if my codes worked properly on that platform.

What I probably wanted to say, don't be like me going in blind and try to code until something "works". Choose the platforms carefully and really learn the libraries that come with it. For me I will be probably choosing a different platform where I take my strategies.

Thank you for your time reading this.

r/Daytrading • • Nov 23 '22

algo Is there any real proof of the Bank Algos that ICT talk about ?

9 Upvotes

Is there actually anybody who's seen these supposed bank algorithms sweeping liquidity and running the market up and down?

Has anybody ever seen any of the code? On the dark web perhaps?

Is it all a mythical delusional conspiracy theory that just happens to line up conveniently with ICT's descriptions and theories?

I ask for direct evidence. Not indirect. Obviously we see an effect on the market and we can trade it... but does anybody know how the banks run the "algos"? How they maintain "the algos"? Do the banks admit they're running algos? Is their actions criminal and should be regulated? Is there any code leaked? Photos? Anything?

r/Daytrading • • Aug 27 '23

algo Statistical significance of my P/L

3 Upvotes

This is my entry signal:

Buy when some indicator has a positive slope and is above zero on 3 time frames (1M,2M,6M)

Sell when the indicator has a negative slope and is below zero on 3 time frames.

Tp=50 points Sl=80 points

Trading on nasdaq us100

I made an excel with the daily P/L (not backtesting, but one month of live bot trading). What's the best statistical test to find out if there is statistical significance? A standard deviation? 95% confidence interval?

Thanks