Trading Update - 7

Update 6
January Trade Review

This post is dedicated to February trades. The algo has not been modified except for some small bug fixes. Both algos that I described previously are being traded.



02/01/2019
$SPY has been really strong the last few days due to the fed not increasing rates. Not a whole lot stands out to me during premarket except $TTNP but it’s too low for the algo to trade at the moment.

I’m pretty tired so I’ll let it trade until 11:30-12:00.

Not a lot going on besides the $TMSR halt craziness. Hopefully that sets the tone for next week. Stopping at 11:00. No trades.

02/04/2019
$SPY is sideways during premarket with no gap. Could go either way. The State of the Union is tomrrow. I hope it doesn’t tank the market like it did last year. I may skip tomorrow and Wednesday depending on how volatile things are. My sleep schedule is pretty weird so I’ll go until 12. I’ve got some sinus pressure like I described in my January post from being sick. I feel way better than the first week of being sick so it’s progress.

Pretty slow but there were some trades. Unfortunately none really worked. $MNGA had a nice runup on some news but couldn’t break out of the flag. $AXSM had a really nice flat top flag but ultimately failed. I’m going to stop at 11 since there’s not much happening. $SPY was chopping around a bunch so I think I’ll just wait until Wednesday or Thursday depending on how the market reacts.

Down about $11 today. Not a lot but it keeps getting more difficult to make up the losses. I’d like to try swing trading $AMD more based off the daily chart but it has to pull back first.

$MBOT and $PYX also had failed flags.



$MNGA 5m/1m candles

$AXSM 5m/1m candles

02/05/2019
$SPY gapped up a bit so I’ll let it trade today. Not sure about tomorrow though. I don’t see much happening so there might not be a trade.

It’s watching 5 stocks by 10:00 and I’m not seeing anything moving. I’ll stop at 11.

Got a trade on $EOLS. It looked like a good setup but it refused to breakout. I was never up on it more than 5c. Algo sold sooner than the stop because of multiple topping candles.

Stopping at 11 due to nothing going on. I’ll let it paper trade.

It paper traded $EOLS around 12:30. Easy win. If I kept live trading it would have made back the loss and been up $4.



$EOLS 5m/1m candles

02/06/2019
Assuming the entire market doesn’t collapse, I plan to trade the entire day. By only trading a few hours per day I am limiting my potential winners. This was proven yesterday after it traded $EOLS again after I had stopped trading live. It made back the gain and more to the point of profitability. I increased the “trade rate” filter from 25 to 50 to make sure the stocks it’s watching are very active.

Only watching 11 stocks by 10:30 and I don’t see much happening.

Today is extremely dead and I want to work on another project so I’ll let it paper trade while I sleep.

No trades. A few were popping up but they failed.

02/07/2019
Big gap down in the $SPY. I don’t see much moving besides weed stocks.

This week has been really crappy. Either Friday starts getting good again or maybe next week.

Only watching 11 stocks by 12 so I’m going to stop it and work on other things.

Not even a paper trade today. I did see a nice $EOLS flag today but it did not meet the requirements. All the volume came in on that single bar. It didn’t matter in this case.

02/08/2019
$SPY is down again so we’ll see what happens.

Nothing going on by 10:20 so I’m just going to paper trade so I can do some other things. I’d really like there to be some crazy runners like $VTVT last year with perfect flags.

02/11/2019
Not much going on again.

Small caps are extremely dead so I’m going to experiment with paper trading by allowing it to trade higher market caps (up to 10B vs 1B).

  1. $EOLS hit the scan and the flag looked great. I manually took it and the algo did a few seconds later. Worked OK but got stopped out for a profit when it moved the stop to $28.97 (whole number stop).
  2. $UNVR drifted down and got stopped out. Stocks like this are why I hate large caps. Nice setup and it just slowly doesn’t work.
  3. $AXGN later in the day. I believe that particular setup requires a small change to make sure candles aren’t completely outside the body of the high.

There is significantly more junk after upping the market cap. This means I also need to increase my other filters like volume and trade count/rate.

02/12/2019
I’m going back to paper trading for the week since I have tweaked the scans and changed the algo slightly to make it hopefully trade better setups.

  1. $CRON. Took a while but hit the target.
  2. $ROKU. Really slow but hit the target after 25 minutes.
  3. $BHF. No fill. This one it definitely missed. Entry was 40.14 and the bid/ask was already 40.15 x 40.20. Plenty of time to get out for a small win as it formed a \/\/ top.
  4. $MAT. Too much resistance near $17. It was nearly identical to the $BHF setup.
  5. $CRON again.
  6. $APHA. Another weed stock at the same time as $CRON. Not as good of a setup since the “high” candle is not above the previous candles.
  7. $BWA. No fill.

So, the early trades were OK but it gave back everything by making multiple trades that didn’t fit the pattern. I’ve fixed those issues and in fact it should have taken $EOLS on 2/7. I hate tweaking the algo constantly because it’s a never ending process but it seems necessary in order to not trade garbage setups.

02/13/2019

  1. $CVE. This exact pattern showed up yesterday on multiple stocks. It seems like this setup is a perfect short opportunity. Float is 1B which is nuts. Sold break even after it topped a bunch. I’m adding a float filter using IEX to avoid 350M+ floats. It ended up hitting the target about an hour later.
  2. $AVLR. Got filled at the top of the candle due to terrible spreads (probably would have gotten somewhere in the middle if it wasn’t a paper trade). Decent win on it.
  3. $LSCC. I was in the shower when it took this one. Only a 10c move but that’s still a win. It topped at 10.50 so it got out. That was the right call because it’s drifting back to the entry.
  4. $CRC. Algo sold for a small loss due to it topping at $19.00. Eventually it got going and ran way past the target.

Pretty decent today. On another note, IB added a few lines to the TWS VM options file and it may have fixed the annoying lag problems I had.

02/14/2019

  1. $TGE. No fill. I may lower the “no fill” delay so if it doesn’t get filled immediately there’s no trade.
  2. $IVC. Failed completely. Eventually hit the target but took many hours. It’s a really nice pullback setup but it shouldn’t have been traded because the high candle was not extended.
  3. $MYOK. Break even. Probably moved the stop too soon. Hit the target eventually.
  4. $GSUM. No fill but if it were live I’m pretty sure it would have since there were lots of orders at the entry. Hit the target of 3.82 and then some.
  5. $GSUM. No fill again. It missed the target by 1c which is just crazy.

One it did not trade was $MRO which had a real nice flag after the daily breakout. It wasn’t on the scan because of the 13B market cap and the float being huge. Still a nice trade. I looked at the 1m chart and it was never down after the entry.

1
2
3
4
5
6
[02/14/2019 10:10:00] Entry 41 @ $16.74, target $17.02, stop $16.62 [ Bull Flag ]
Trailing stop: 16.62, 16.77
[02/14/2019 10:30:00] Exit @ $17.03 [ $0.29 ]
Drawdown: $0.13 / -0.77%
Max profit: $0.29 / 1.73%
P/L: $11.89

02/15/2019
Friday! If the changes do OK all next week I may go live with it the week after.

  1. $SAEX. Failed almost instantly. Nice setup though.
  2. $YETI. Went up a little, double topped, dumped. Algo sold it sooner so the loss was less.
  3. $PYX. Nice looking setup but failed. It crashed hard then eventually came back to the entry.
  4. $SAEX again. Instantly stopped out. Dumped really hard, and that’s why you have stops.

Pretty slow day. Not sure if all Friday’s have been like this or it’s just slow.

I want to add a risk/reward value so I can make sure the reward is there otherwise there’s no point in going for 1:1 or even less. Also I was thinking about looking at average green candle vs. average red candle sizes to see if that would improve accuracy.

Market is closed on Monday.

02/19/2019
One trade on $RIOT. I think I need a 200 EMA check because it ran straight into it and dumped. Nothing else.

02/20/2019
I increased the market cap to 15B to see what it’d do. I slept while it paper traded and they were all pretty good.

  1. $I. OK trade, got out when it double topped.
  2. $NVTA. Choppy flag, small loss.
  3. $CRON. Awesome setup, basically top ticked it.
  4. $X. Steel company. Tiny winner. Perfect exit since it dumped right after.
  5. $HUYA. Nice setup and it was underestimated severely.

Some really nice trades today with only a single loser.

02/21/2019
No trades. A few were popping up but by the time it made a new high it didn’t meet the requirements or the risk/reward wasn’t good enough.

I’ll probably give it another week to see what it does then go live. I don’t want to have only a weeks worth of trades to go off of.

02/22/2019

  1. $INFN. Stopped out break even.
  2. $AAOI. Late day flag. Dumped first then ran so stopped out for a loss. Kind of annoying how a stock has to crash out of a flag before it finally goes.

02/25/2019

  1. $LB. First pullback which looks great then a giant dump.
  2. $AAOI. Lost on this one on Friday but it won this time. Barely.
  3. $CIFS. Another decent looking setup that failed before getting to the target.

I’m starting to lose hope and maybe I should just reverse the strategy to short it first with a stop at high of day. Every gain is small and every loss is large. If it wins every trade like on the 20th it’s still smaller than two average losses.

02/26/2019

  1. $FTCH. Finally one that worked. It didn’t go instantly but did hit the target. Didn’t get a fill but it should have with a live account.
  2. $SOLO. Instantly dumped. Looking back at it there’s a nice morning flag that did work but was not traded. Hm.

The winners did outweigh the losers today.

02/27/2019

  1. $MDR. Garbage.
  2. $ENPH. Another turd. I’ve seen this one run far in the past.
  3. $OSTK. Extremely slow but hit the target. First flag wasn’t taken due to high RSI.

I’m still finding issues where the candles aren’t up high enough to buy. The second bad flag it traded on $OSTK was garbage even though it worked eventually. I added the RSI > 79 check to filter out really extended junk but that caused it to miss the first flag. I think that indicator is useless for algo trading.

02/28/2019
I’ll write another recap post for this month soon.

  1. $CRON. Stopped out break even. Not a bad trade.
  2. $HZNP. Finally got a move but it couldn’t hit the target. Break even. Many chances to sell for a profit on this.

Quite a few in the morning that did not have the right risk/reward. $ZSAN would have worked but missed the target by 3c.

Trade Review - February 2019



Disclaimer

I am not a registered financial adviser/broker/anything. Use this information for entertainment/informational purposes only. Any tickers mentioned are not recommendations to buy/sell/or sell short. They are used as examples only.

Please remember that past performance may not be indicative of future results.

Trade Review - January 2019

I’ve learned quite a bit from letting my algo trade during January. It started off pretty good with a couple of small winners which is exactly what I wanted. I then had a few losses that spiraled out of control and forced me to size down after I started to sabotage myself.

After a string of bad trades I went back to paper trading and had some gains which is super annoying. The week after that I got sick and had to take two weeks off in order to fully recovery. During that time I was paper trading still and some worked out.

It was a pretty rocky month with only 2 full weeks of trades at the beginning. I’m ending it down about -$25 which is unfortunate but I should be able to make that up eventually.

Here’s to February being much better!



Disclaimer

I am not a registered financial adviser/broker/anything. Use this information for entertainment/informational purposes only. Any tickers mentioned are not recommendations to buy/sell/or sell short. They are used as examples only.

Trading Psychology - Self-Sabotage

This post is about something I discovered while algo trading recently. The issue I seem to be having is due to multiple losses and fear of another loser or fear of losing money in general. Despite letting an algorithm trade for me, I still end up screwing up the trade by taking losses too early without letting the trade play out and work.

Here is the definition of self-sabotage from Psychology Today:

Behavior is said to be self-sabotaging when it creates problems in our life and interferes with long-standing goals.

It all goes back to “Trading in the Zone” by Mark Douglas. My losing trades are mostly caused by myself not fully trusting the algo or not fully accepting the risk of each trade.

I started algo trading at the beginning of this year and actually found a little bit of success; then I had one “large” loser that stopped me out of a trade due to the stop loss not being at the correct price. That trade would have worked if it were not for that technical error. Next, there was a trade on $USAT that wasn’t really working so I stopped my algo when it was about to trade $MBOT. I couldn’t stand having yet another losing trade.

Because of that first big losing trade, I stopped trusting it to make proper decisions despite seeing trades work over and over in my paper account. And guess what happened with the $MBOT trade it wanted to take? An easy win that worked almost instantly that would have taken out both losses. In fact, I would have been profitable on the day because it would have sold $USAT sooner rather than getting stopped out.

$MBOT 5m candles

I am sabotaging myself by not letting it take every trade or not letting the algo decide when it’s not working and it should get out. It follows rules so I don’t have to think.

Today, on $MBOT again, I did not like how the stock was acting so I sold it too soon. The trade worked without ever touching my stop price.

$MBOT 5m/1m candles

The Solution

The only thing I can come up with is to size down even further so the risk is a $5 max loss instead of $10. This is not much money either way but it feels like a lot if you have one double digit loser after another.

Once you’re in a trade you have to stop thinking. Risk is set, there is nothing else to do but wait. Some trades will work instantly and others will take time to get going.

This week has been pretty tough and the most trades I’ve ever taken in a day or even week. I’ve sized down to $5 of risk so tomorrow I’ll just sit on my hands and let the algo trade each setup.

I have “Trading Psychology 2.0” on my shelf but it’s tough to get through. I’ll force myself to read it at some point.

At least I’m aware of this problem so I can try working towards a solution. I don’t need income from trading so it’s not a “life or death” situation. These small losses don’t matter in the beginning. I’m only just getting started.

Trading Update - 6

Update 5 - Bull Flag 2 Trades

I can’t believe I’m already on part 6 of this series and it’s 2019. I’ve learned quite a bit from watching it paper trade the last few months.

Now that it’s January, I’m ready to test it semi-live. There are now two algos: standard bull flag algo from the other post, and another one that is more specific that trades perfect pennants and bull flags. Both are very similar in the way they look for the patterns and take the trades. The first algo sometimes takes choppy flags but also has ones that are perfect but don’t meet the critera of the pennant algo.

  1. Standard bull flag algo
    • Orders are submitted but not transmitted so I get to choose if it trades them
    • Sometimes finds choppy flags
    • Not as specific as the pennant algo but is the majority of trades and gains
  2. Pennant algo
    • Transmitted live
    • Looks for perfect pennant setups and bull flags
      • Must be all red candles (except the high candle)
      • Candle tops / bottoms must be inside the high candle
      • Pennants / flags: candle tops must downtrend along with volume
      • Pennants: candle bottoms must also uptrend

If the flag doesn’t meet the requirements of the #1 algo it shouldn’t trade the #2 algo due to how similar they are. I plan to let the algos do their thing unless I see an exit indicator. It’d be nice if the first trade it took was a winner.



01/02/2019
Today it’s watching a lot more stocks compared to the holiday weeks even though the morning was painfully slow.

One attempted trade on $CRC that I canceled. Not a bad setup but the last time it traded it it dumped off then ran. Not really a fan of this stock. It did manage to hit the target after a slow grind up.

1
2
3
4
5
6
[01/02/2019 10:40:00] Entry 45 @ $17.19, target $17.65, stop $16.97 [ Bull Flag ]
Trailing stop: 16.97, 17.22
[01/02/2019 11:00:00] Exit @ $17.38 [ $0.18 ] (exit indicator)
Drawdown: $0.19 / -1.10%
Max profit: $0.18 / 1.04%
P/L: $8.32

I canceled another on $WATT. I’m not seeing any crazy volume stocks so none of these look like they will work. It also hit the target and would have been an $18 gain.

1
2
3
4
5
6
[01/02/2019 11:30:00] Entry 90 @ $6.34, target $6.54, stop $6.23 [ Bull Flag ]
Trailing stop: 6.23, 6.37
[01/02/2019 11:40:00] Exit @ $6.55 [ $0.21 ]
Drawdown: $0.10 / -1.58%
Max profit: $0.16 / 2.48%
P/L: $18.90

I’m thinking tomorrow I’ll just let it transmit all the orders it wants. I’m like trying to predict which ones will work and which ones won’t but that’s not how the market works. Worst case scenario I can just sell it back instantly for a commission loss if the flag is garbage looking.

01/03/2019
Everything is live today. Big gap down in the $SPY like yesterday. Hopefully I get a win - even if it’s $2.

Watching 3 stocks by 10:00. 5 by 10:30. 9 by 11:00. If the market continues to sell off it’s unlikely there will be a trade today. Never know for sure though.

Market started to bounce around 11:00 similar to yesterday.

Stopping it at 1:00 PM. $SPY is just sideways in a range and it’s only watching 39 stocks. Not much going on today in terms of small caps. Eventually it will trade something like it did yesterday.

Try again tomorrow.

I just realized something with my $CRC thought process from yesterday and it goes back to what Mark Douglas said in Trading in the Zone. Each trade is random and unique even though we believe in our minds that what happened previously will have the same outcome again. I thought $CRC wouldn’t work because it hadn’t before. If I have more data to back up my reasoning, like with $NBEV, then I can assume flags usually do not work on a particular stock.

01/04/2019
$SPY is up a lot from yesterday’s close. I’d like to see it get over 250, but there’s going to be a lot of resistance. Hopefully we see similar action to Wednesday with more stocks moving.

Not a whole lot moving this morning.

So I finally got an algo trade and it was 2. $FLXN and $TWTR.

Both of these I manually took profits/losses. $FLXN just couldn’t get over prior close so I sold when it started to crash into $12.25. $TWTR was really choppy and slow so I took profit on the ask when it finally broke over the high. It didn’t hit the target anyway so my exit was solid.

The $SPY did manage to get over $250 like I wanted due to some fed news which is really good. Monday should be interesting if the momentum continues.



$FLXN 5m/1m candles
$TWTR 5m/1m candles

01/07/2019
$SPY held most of its gains but is coming down a little during premarket. I’m seeing quite a few things moving around which is good. I just want to get one good win in so I can build up a cushion. It doesn’t really matter because over time this strategy should come out on top. I just like the idea of trading with profits and not losing money in my account.

It’s almost 10:00 and it’s only watching 7 stocks. I’d be OK with it not trading anything since there’s not much moving besides $ROKU and $ARRY.

One trade on $EPZM for a $6 gain. I was watching this setup a few minutes before it took it but I was hoping it’d dump first because of that huge topping wick. I manually took profit into a large spike. I seem to be pretty good at determining when I should get out. So far no amazing trades that work instantly. Earnings season is coming up so that should get really interesting.

Stopping it at 11:00 AM.



$EPZM 5m/1m candles

01/08/2019
$SPY is still climbing which is great. I just want to keep building up that cushion and hopefully one of these days get a full move out of one of these trades.

I don’t see too much going on so I doubt there will be a trade. It does end up surprising me a lot though.

Only watching 5 stocks by 10:00. Not looking too good.

Nothing going on today and the $SPY is now below yesterdays close so I’m stopping it at 11:00. $TMDI looked really promising for a 5m setup but it failed. I can’t wait for earnings season to start.

No trades.

01/09/2019
$SPY is up again. We’ll see if it holds up. Not too much going on during premarket but there could be something later on.

It’s watching more stocks today but there’s not a lot going on. $TWTR, $HUYA, and $LJPC had early flags but they didn’t meet the requirements. It was about to take $WATT but it failed and it didn’t look good. $LJPC had another flag around 10:30 but it looked way too choppy. It somewhat worked but the backtest shows it would have gotten out due to a double top.

I’m just going to try again tomorrow. Everything is crappy today. I don’t want to push my luck until earnings season.

01/10/2019
$SPY finally gapped down. It may go green later. Can’t really predict that. I got up a bit late so I’m just going to paper trade it today. I don’t see much going on anyway so it may not even trade.

No trades.

01/11/2019
The last half of this week has been so slow I don’t have the urge to wake up early. $SPY is downtrending and it’s watching 6 stocks by 10:00. It may trade something since it’s been a while without a trade. I’m just paper trading it now. On Monday I’ll get back to live trades.

One paper trade on $AXSM. It sold for a $3 gain when a double top occurred and if it stayed in it would have hit the target. Not bad I guess.

1
2
3
4
5
6
[01/11/2019 12:10:00] Entry 90 @ $7.68, target $7.88, stop $7.57 [ Bull Flag ]
Trailing stop: 7.57
[01/11/2019 12:30:00] Exit @ $7.71 [ $0.03 ] (exit indicator)
Drawdown: $0.13 / -1.69%
Max profit: $0.06 / 0.77%
P/L: $2.57

No screenshots because I only want to catalog live trades here.

I think the ATR indicator is broken in IB or the smoothing done by TA-Lib is different. The ATR for all of the candles in IB are less than 0.10 and the algo would not trade if they are below that. Odd.

01/14/2019
This is the start of the earnings season! All I want is a single win to keep building that cushion.

Significant $SPY gap down but it is earnings season so I still want to trade. Maybe it will reverse or there will be some earnings winners not tracking the market.



Got a trade on $SAEX that literally touched my stop for not even a second then ran. I’m not sure if that’s because a trade occurred below my stop or the bid dropped below it. If I didn’t get stopped out I could have had a small gain on this since it blasted through my entry afterwards. If I let the algo do its thing it would have been a break even trade.

$SAEX 5m/1m candles

Another trade on $USAT. I closed my algo app at this time since it was looking to trade $MBOT next. I should not have done that since at some point it has to have a win. This one would have been about a $7 loss instead of a full $11 if I didn’t close the algo.

So really I should have only been down like 8-10 total and maybe I would have let it trade $MBOT then. Ugh.

$USAT 5m/1m candles

1
2
3
4
5
6
[01/14/2019 10:35:00] Entry 43 @ $5.40, target $5.94, stop $5.17 [ Bull Flag ]
Trailing stop: 5.17
[01/14/2019 10:35:00] Exit @ $5.95 [ $0.55 ]
Drawdown: $0.82 / -13.46%
Max profit: $0.09 / 1.51%
P/L: $23.65

(I don’t think the drawdown / max profit values above are working correctly so just ignore them)

$MBOT would have worked but I decided against it because all these trades have been garbage. I can’t win. I should have let it do its thing, but I could not stand having another loss. I can afford to lose $20+ otherwise I wouldn’t be trading. I just hate seeing my account value drop.

You don’t get to choose which trades will work.

I will say that my fills are pretty solid on the stop losses. It’s not many shares but I haven’t really gotten any slippage on these.

I went back and looked at the trade data. Not a single trade occurred below my $5.80 stop loss which means stops get triggered if a trade occurs at or below your stop price. This can be changed in TWS but I don’t see anything better than “Last” which is the default. I’ve changed the stop price to be 1c below which should prevent stupid exits like this. It should not have been a loss!

Here’s the tick data for my trade time period. I’ve highlighted my exit. Somehow I got 5.81 and not 5.80 so either IB is doing a pretty good job or they’re slow on the executions and the bid popped up for a second. Entries/exits were both executed on ARCA.


$SAEX tick data

01/15/2019
$SPY is up a tiny bit today and I’m seeing quite a few low priced stocks up. I plan to let the algo trade everything and never prevent it from trading. If you try to avoid more losses you will only end up with more losses.

Despite $MBOT going nuts it’s only watching 4 stocks by 10:00. There might not be a trade today since yesterday there were a lot. I plan to stop it around 12:00 if nothing is going on. The overall market has been straight up and the $SPY tapped 260. It needs to get over that level otherwise I expect there to be a dump.



Got a trade on $MBOT on the 5m flag setup. Lost $6 on it. I decided to bail early because it should have had instant resolution but the move got stuffed. The timing for it ended up being off and this would have been a win if I had held.

$MBOT 5m/1m candles

Next trade on $VHC. Another loser but this time I sized down to $5 of risk and let my algo do whatever. It sold it early when it topped at 5.50. This was amazing timing since it dumped on the next candle.

Good thing I adjusted stops to be 1c lower because this one dropped instantly to my stop price then came back up. I got a better exit because of that.

$VHC 5m/1m candles

Stopping at 11:00. Nothing else going on and today is not a good day for me. I will let it paper trade the rest of the day though.

I looked at the stats and currently the win rate is only 28% and this is because I got screwed on $SAEX, didn’t let it trade $MBOT yesterday, and sabotaged myself with $MBOT today. Otherwise the win rate is about 62%.

This is why I decided to algo trade. So it could find the right setup and I don’t have to worry about the stop price or where to get out. It does it all. Of course that doesn’t prevent self-sabotage and fear of losing. I’ve had so many losers in a row now that I never expect any trade to ever work. At least I am aware of this problem and can try to avoid making the same mistakes.

Trading is hard and I’ll make back the losses even if it takes months.

01/16/2019
$SPY opened above $260 which is great. I couldn’t sleep much so I’ll be stopping at 11:00 so I can go back to bed. I’ve sized down to $5 of risk so even if I lose it doesn’t matter. Somehow $MBOT is still going.

Since I sized down I was able to just walk away after it took a position on $CENX. The algo sold due to a double top for a $2 loss. It’s a very slow stock. One of these trades has to work.

I realized earlier that accuracy is much higher since $CRC and $WATT worked from before but I didn’t let it trade them. Have to let it trade everything otherwise you have an accuracy skewed to the losing side.

Not as much stuff going on today so I’m stopping at 11 so I can sleep. I’ll let it paper trade the rest of the day.



$CENX 5m/1m candles

I let it paper trade the rest of the day and it got a perfect win on $UNFI. I can’t believe this strategy seems to only work when I paper trade it. It’s so frustrating.



1
2
3
4
5
6
[01/16/2019 14:45:00] Entry 33 @ $13.20, target $13.57, stop $13.05 [ Bull Flag ]
Trailing stop: 13.05, 13.23
[01/16/2019 14:50:00] Exit @ $13.58 [ $0.38 ]
Drawdown: $0.24 / -1.76%
Max profit: $0.32 / 2.39%
P/L: $12.54

01/17/2019
I’m taking today off since I developed a sore throat yesterday and I couldn’t sleep. I don’t know if it’s just too dry and cold now or what. I really do not want to take a day off but I feel like I need to. I may also take Friday off so I can get back to it on Monday. This week has been crazy.

No morning paper trades. $FOSL was looking good but it didn’t take it. Would have worked out OK but it’s slow.

Later it got a trade on $ALDR. It almost hit the target after slowly grinding up. There was plenty of time to exit around $12.50.

1
2
3
4
5
6
[01/17/2019 15:15:00] Entry 41 @ $12.36, target $12.57, stop $12.24 [ Bull Flag ]
Trailing stop: 12.24, 12.39
[01/17/2019 15:30:00] Exit @ $12.47 [ $0.11 ] (exit indicator)
Drawdown: $0.21 / -1.68%
Max profit: $0.05 / 0.40%
P/L: $4.51

I may trade tomorrow if I start feeling better.

01/18/2019
Took today off as well. There were a few paper trades. One on $HUYA and another on $HEAR. $HUYA got stopped out for basically break even. $HEAR was perfect and slowly grinded up to the target.

Yet another flag on $OSTK near end of day. Up $5 on that. Crazy how if I just stop screwing with things it ends up with gains.

Pretty good paper trading day. I just realized Monday is closed which is perfect since I still feel a bit sick.

Accuracy is 76% if I include the trades where I screwed them up, the $SAEX one, and the recent paper trades. That’s insanely good.

01/22/2019
Starting to feel better but not enough to trade live. I want to start trading all day and I don’t think I’m up for that while sick. Maybe tomorrow but I might just take the entire week off to recover.

Not much going on. Huge market dump. One paper trade on $AXSM for a loss.

01/23/2019
I’m writing this the night before. Taking Wednesday off again since I’ve got a slight headache now and I just want to not be sick when I trade. This could be the start of a new downtrend in the $SPY so I’m not expecting this week to be that great.

Got one paper trade on $SPI for a small winner. I’ll take it considering the entire market dumped today.

01/24/2019
Also writing this one the night before. Still a bit sick so if I don’t wake up for the open then I won’t trade live. Anthem VIP demo comes out on Friday in the morning, so if I’m awake for that I may trade live for a few hours but otherwise I’ll be playing that instead. This week has been pretty slow for flags which is great since me being sick was perfect timing.

One trade on $TBLT but it didn’t get filled. Would have gotten stopped out for break even.

Very slow this week compared to last week so I’ll probably just skip Friday again and let it paper trade while I play Anthem. Next week should be better.

01/25/2019
Took today off again.

Two trades on $OSTK. Neither of them had much follow through. The second trade did move up a bit and it basically got out break even.

$MGNX had this insane topping wick that I almost want to write code to ignore. Got a tiny move up then it dumped.

The second $OSTK trade would have made back the loss then on $MGNX there were several signs to get out like two topping wicks in a row. So today could have been profitable but it was pretty crappy.

Another trade on $OSTK. No follow through.

This week was very slow and that seems to happen a lot. Every other week tends to be good.

01/28/2019
This is the last week of January. I’ll probably do a review of the month then start another post with more live algo trades. I’m finally not sick so back to live trades, and I want to let it trade all day since there have been some trades near 2:00 PM that worked well.

Big $SPY gap down and I don’t see too many stocks up premarket that look interesting. We’ll see what happens. If there’s nothing by 12 I might just go to sleep.

Got a trade on $AWSM that hit the target perfectly and more. I took it early because my heart was racing for no apparent reason. I think taking that week off made me forget about risk management and letting trades play out.



$AWSM 5m/1m candles

I’m taking the rest of the day off. There was nothing else really going on.

01/29/2019
I was really tired so I slept in until about noon. I don’t think much was going on but it may have traded despite that. $AMD had a huge earnings spike after hours. If it gets back to $16-17 in a few weeks I’ll be buying some.

I’ll try to be up tomorrow morning for live trades, but I’ve developed some sinus pressure from my runny nose so if I feel like garbage I’ll be sleeping in again.

01/30/2019
Head is hurting a bit so I’ll just take it easy and sleep all day. When I wake up I’ll see what it paper traded.

Algo didn’t start. Thanks Windows.

01/31/2019
Last day of the month. I’m doing something that is crazy CPU intensive so I don’t want to live trade. Also, I’m pretty tired so at this point I’ll probably just wait until February to get things going. Finally not as sick so that’s nice.

Got a paper trade on $SXTC. Ended up being break even but plenty of time to sell at $7.90. Crazy spreads on it.

Surprisingly only watching 25 stocks by EOD so only that one trade in the morning. It wasn’t terrible just a little early and rejected $8.


January Trade Review



Disclaimer

I am not a registered financial adviser/broker/anything. Use this information for entertainment/informational purposes only. Any tickers mentioned are not recommendations to buy/sell/or sell short. They are used as examples only.

Please remember that past performance may not be indicative of future results.

Trading Review 2018

2018 was interesting. I traded a little at the beginning but the market felt even more difficult to trade after the state of the union address. I just couldn’t find anything I liked so I ended up not trading much at all. I had a few losses but I can’t even remember them now because they were so long ago.

My main wins were from swing trading $ALLY and $AMD. I successfully dip bought $ALLY when it hit my daily trend line and I sold it the next day for a nice win on 100 shares.

Most of the year I was working on my algo trading application to integrate with IB then actually writing algorithms. I experimented with different setups like red to green, 5m/15m opening range break out, MACD, and bull/bear flags. There were some that worked but bull flags have been the most consistent. Bear flags work too but I couldn’t make them as consistent. I’ll have to revisit them since I think they need a slightly different algo to work and you can’t just flip a bull flag upside down like some have said.

I don’t think I watched a single Tim DVD like I said I would from 2017. I’ve seen them all and I still don’t know what his strategy is. There’s nothing about how to trade flags or any technical indicators/patterns. It’s just support/resistance, which is fine, but I need some type of chart pattern to trade. I can’t just randomly buy some dip and hope it holds. That’s not feasible. I need a clear entry and stop loss.

This is why I like Kunal (and even Ross). I said in another post that I based my flag trades on his “how to trade the open” presentations that he does everywhere. He described the setup so well that I was able to mostly automate it. I mean it still has losses or even a string of losses but that could just be the recent small cap market being slow.

I started a YouTube channel to document my algo trades and have had some insane wins. When bull flags work they really work.



profit.ly 2018

Trading Goals for 2019

  1. I’ve been letting my algo trade live recently, but it hasn’t taken any trades yet. For 2019, I want to try and be here every day and let it trade as much as possible if it looks good. I have the ability to manually transmit the orders in case the setup is terrible or I know the stock never makes moves. I’m hoping January is good for 5m flag setups.
  2. I’m writing this on the very last day of 2018 and the past few days I’ve started working on adding GDAX support for my trading app. I’ve backtested bull flags on the 1H chart going back 2 years and it looks promising. I want to focus on that as well as stock trading.

Crypto Datasets

I had a hard time finding 1m datasets for LTC so I wrote some code to pull all of it from 2017 until 2018 on the GDAX exchange. I cannot guarantee the accuracy of this data. Use at your own risk.

The format is a SQLite3 database. It should be easy to export to a CSV if necessary. Use 7-zip to extract.

Bitcoin 1m data going back further than 2016 can be downloaded from Kaggle.

IB Fixed vs Tiered

I only trade small positions at the moment so this is just my opinion.

Interactive Brokers has two commission options available: fixed and tiered.

Fixed

Fixed is exactly what it sounds like, you pay a fixed rate of 0.005/share with a $1 minimum (plus a few pennies for FINRA fees and whatnot). This means you can trade up to 200 shares for $1. IB will keep the rebates for themselves if there are any.

Tiered

Tiered is 0.0035/share (depending on your volume) with a 0.35 minimum but you pay ECN fees and keep rebates if there are any. You also have the option to direct route.


So which is better? Anything over 200 shares it is better to use fixed unless you always add liquidity and can take advantage of ECN rebates. However, 100 shares and under it’s better to use tiered. We’re only talking about a few cents difference per trade and obviously if you’re that worried about a few cents on commissions your strategy probably isn’t valid.

In my case, with testing algorithms, I’ve always been on tiered with their paper trading account. Fees end up being between 0.20 and 0.60 which is essentially free. My algorithm has a max loss of $10 and it sizes in according to the stop price. So every trade it takes is going to be 100 shares or less for the most part.

When I go live I will most likely switch to tiered so even if I get stopped out for a tiny $1 win I won’t lose because of commissions. This should make testing less stressful.



Disclaimer

I am not a registered financial adviser/broker/anything. Use this information for entertainment/informational purposes only. Any tickers mentioned are not recommendations to buy/sell/or sell short. They are used as examples only.

Gaming on a Macbook with Insane Battery Life

I watched one of LinusTechTips recent videos where he demoed game streaming from a service I hadn’t heard of called Shadow (coupon: RYA1BMUE). I was intrigued by the fact that you get a full Windows 10 VM with 8 cores, 12 GB RAM, and a GTX 1080 or Quadro P5000 to install whatever you want onto (besides mining) with very low latency.

It was only $15 after the coupon code (use mine if you decide to try: RYA1BMUE) so I said why not. So, after the initial setup there was massive latency of 1 second or more even though my ping is 7ms to the date center in New York. This was solved by rebooting the VM and it’s been fine ever since. However, there is still some latency so for multiplayer FPS games like CS:GO or Overwatch I would not recommend it. Anything singleplayer or co-op like Fallout 4 or Left 4 Dead it would be fine.

They must be overprovisioning their service so this is essentially how it works (my best guess):

  1. They expect most people to not be gaming while their service is active so they can overprovision and have more paying customers. This is actually a good thing because it brings the cost down for everyone substantially.
  2. Your individual VM storage lives on another server in the DC.
  3. When you open the Shadow software and launch your Shadow, it is spun up on a random server with your block storage attached.
  4. When you close the Shadow software, your VM is turned off after several minutes so someone else has the chance to use the hardware.



That’s a brief overview of my thoughts on it. Now, about laptop gaming.

There’s this little utility called Volta that can be used to undervolt and limit the maximum wattage of your CPU on macOS. On Windows you can use Intel XTU. I don’t think AMD has a way to do this yet.

Basically, what I did was limit the maximum wattage of my 2013 Macbook Pro 13” to 5w and ran Shadow for game streaming. My Macbook got a little warm but never hot (fan was off the whole time) as I played Left 4 Dead on a bed comforter.

Activity Monitor said I had about 6 hours of battery life while Shadow was running which is pretty good considering it was hogging about 40% of the CPU. I have a Ubiquiti AP so even playing over WiFi there wasn’t much of a difference between wired.

It’s fairly impressive but since I have a PC better than the VM, it would make more sense to stream the game locally for even less latency. I haven’t tested Steam in-home streaming with the capped power limit so that may work. Last time I tried it the quality wasn’t very good and it killed the battery quickly.

SMART - Error X occurred at disk power-on lifetime

I was setting up a Debian server with all SSDs and I kept getting a strange error that caused mdadm to not be able to flush data which made the entire system lock up.

I decided to check the SMART log and I saw a strange error. All of the SMART attributes are good with no reallocated sectors. I’m using all Intel SSDs and I’ve never had a problem with them until this one.

The error does not appear to be the drive itself as I tested another Intel 730 SSD and even moved a known good drive to the port and it still ocurred. It’s actually a problem with the cable. Most likely it was just loose and not making perfect contact with the SATA port on the motherboard. I moved the cables around and I have yet to see it happen again.

One strange thing is the other 730 drive I tested already had a bunch of these errors. I do not recall having issues with it so maybe it was from unplugging it while it was on?

As you can see I also ran an extended SMART test and it passed just fine.

TL;DR Check the SATA cable and reseat it.

SMART (Intel 730 240 GB)

SMART (Intel 730 480 GB)

Docker - MSSQL 2017

Microsoft has released MSSQL for Linux and they even released a docker container for it. This makes things pretty straight forward to get running.

There are some issues with ZFS datasets because ZFS does not support O_DIRECT. There’s a hack to get it working but it did not for me. It works fine with ext4 though.

  1. Download the container.

    • docker pull mcr.microsoft.com/mssql/server:2017-GA-ubuntu
  2. Configure the systemd server. Change your SA password and the persistent database path (mine is /mnt/db).

    • /etc/systemd/system/mssql.service
    • 1
      2
      3
      4
      5
      6
      7
      8
      9
      10
      11
      12
      Description=MSSQL
      After=docker.service
      Requires=docker.service
      [Service]
      Restart=always
      ExecStartPre=/usr/bin/docker pull mcr.microsoft.com/mssql/server:2017-GA-ubuntu
      ExecStart=/usr/bin/docker run --rm -e ACCEPT_EULA=Y -e SA_PASSWORD=PASSWORD -e MSSQL_PID=Express -p 1433:1433 --name mssql -v /mnt/db:/var/opt/mssql mcr.microsoft.com/mssql/server:2017-GA-ubuntu
      ExecStop=/usr/bin/docker stop mssql
      [Install]
      WantedBy=local.target
  3. Use a Windows PC to access the database using SQL Server Management Studio.