Friday 19 December 2014

Week of 2014 DE 12

(This is last week's summary, posted a week late).

IWM fell by 2.6% this week, while my account fell 1.9%.  The loss-floor has risen to -10.5%.

End of week allocations:

Net 9% equities, 30% silver, 26% cash
% gain
size
Max loss
Sym Buy Fri Mon Tue Wed Thu Fri Beg End
ATML NO24 +1.0 14 +0.7 14 +0.9 14 +0.4 14 +0.7 14 +0.6 14 -0.6 -0.5
YHOO NO26 -0.2 13 -0.5 13 -0.8 13 -0.8 13 -0.8 13 -0.8 0 -1.1 -1.1
UWM NO28 +0.2 14 -0.1 14 +0.3 14 -0.3 14 -0.2 14 -0.5 14 -0.8 -0.9
AGQ DE04 -0.3 13 -0.1 14 +0.9 15 +1.0 15 +0.9 15 +0.9 15 -0.8 -0.1
URTY DE04 +0.3 14 -0.2 14 -0.6 14 -0.6 14 -0.6 14 -0.6 0 -1.6 -0.6
TNA DE08 -0.5 10 -0.5 10 -0.5 10 -0.5 0 -0.5 -0.5
TZA DE09 -0.7 11 -0.1 11 -0.3 11 +0.1 11 -0.8 -0.8
[cash] -0 0 -10 -10 -0 26
IWM   +2.2   +0.9   +2.6   +0.4   +0.8   -0.4
me -5.3 -7.2 -7.0 -7.3 -7.1 -7.2
floor -11.2 -10.6 -10.9 -10.6 -10.6 -10.5

URTY: The stop rose sharply Monday night because IWM fell below its SMA(s).

[cash]: Negative balances for much of the week — I bought TZA with unsettled funds, but kept it until the funds settled.

Stock-trading robot

Ticker
Symbol
Buy dateBuy priceSell dateSell priceAcct Profit
ModelActualMAModelActual M A M A
UWM NO 21 NO 28 12:58 $85.85 $85.72 (Not yet)
ATML NO 24 09:30 11:31 $7.41 $7.58 (Not yet)
YHOO DE 04 09:30 NO 26 09:30 $50.19 $51.56 DE 09 09:30 $48.75 $48.58 -0.40% -0.76%
AGQ DE 04 09:45 $42.03 (Not yet)
URTY DE 03 15:00 DE 04 11:00 $85.90 $86.52 DE 09 09:30 $82.89 $82.55 -0.86% -0.59%
TNA DE 08 11:00 DE 08 11:27 $77.70 $78.24 DE 08 15:00 14:13 $74.08 $74.10 -0.54% -0.53%
SRTY ¹ DE 08 15:00 (Skipped) $34.52 DE 09 13:00 $34.00 -0.16% +0.00%
TZA DE 09 10:00 $13.70 $13.72 (Not yet)
YHOO ² DE 10 (Skipped) $50.33 DE 11 $49.54 -0.24% +0.00%
YHOO ³ DE 12 (Skipped) $50.33 (Not yet)
SRTY ² DE 12 11:00 (Skipped) $35.63 (Not yet)

ATML: There is a “sell” order for Monday’s open.

TNA: Robot purchase failed due to not enough settled cash.  I put in a reduced order using available cash, but shouldn’t have bothered because the market dropped sharply right after that, and kept going until it hit my stop.

SRTY: Failed to buy on Monday due to lack of cash.  Failed to buy on Friday because robot ran out of memory at 10am.  I should add a batch job to reboot the server every morning.  I should try a newer version of Opera or maybe switching to Firefox to reduce memory leakage.

TZA: On Wednesday, IWM’s PPO rose above my cutoff line, but its price was falling so no “sell” order was issued.

YHOO ²: Skipped due to lack of cash.  Would have been a loser.

YHOO ³: Skipped due to lack of interest in bullish moves during what seems to be a downward trend.

Monday 8 December 2014

Week of 2014 DE 05

IWM rose by 0.9% this week, while my account fell 0.5%.  The loss-floor has fallen to -12.2%.

End of week allocations:

97% equities, 26% silver, 10% cash
% gain
size
Max loss
Sym Buy Fri Mon Tue Wed Thu Fri Beg End
[out] 11 20 20 20 20 20
URTY ¹ OC28 +1.3 15 +0.6 15 +0.6 15 +0.6 15 +0.6 0 -0.5 -0.5
ATML NO24 +0.5 13 +0.3 14 +0.6 14 +1.1 14 +1.0 14 +1.0 14 -1.1 -0.6
YHOO NO26 +0.0 13 -0.4 13 -0.3 13 -0.4 13 -0.3 13 -0.2 13 -1.1 -1.1
UWM NO28 -0.0 14 -0.4 14 -0.1 14 +0.1 14 -0.0 14 +0.2 14 -0.8 -0.8
SRTY ¹ DE01 +0.0 11 -0.2 10 -0.2 10 -0.2 10 -0.2 0 -0.8 -0.8
SRTY ² DE02 -0.1 11 -0.2 10 -0.2 10 -0.2 10 -0.6 -0.6
AGQ DE04 -0.0 14 -0.3 13 -0.8 -0.8
URTY ² DE04 +0.0 14 +0.3 14 -1.5 -1.6
[cash] 34 14 3 3 -10 -0
IWM   +1.3   -0.2   +1.0   +1.9   +1.4   +2.2
me -4.8 -6.5 -6.1 -5.6 -5.8 -5.3
floor -10.1 -9.8 -9.8 -9.1 -11.3 -11.2

[out]: Withdrew more money on Monday to put food on the table for my family.

URTY ¹: Sold at low-of-week.  :-(

ATML: Doing great!

[cash]: Negative balance on Thursday — I bought URTY with unsettled funds.

Stock-trading robot

Ticker
Symbol
Buy dateBuy priceSell dateSell priceAcct Profit
ModelActualMAModelActual M A M A
FRED OC 20 (Skipped) $14.31 DE 03 $14.27 -0.07% +0.00%
URTY ¹ OC 28 13:00 12:00 $79.36 $79.03 DE 01 11:00 $83.10 $83.11 +0.70% +0.64%
UWM NO 21 NO 28 12:58 $85.85 $85.72 (Not yet)
ATML NO 24 09:30 11:31 $7.41 $7.58 (Not yet)
YHOO DE 04 09:30 NO 26 09:30 $50.19 $51.56 (Not yet)
TZA DE 01 10:00 (Skipped) $13.71 DE 03 11:00 $13.07 -0.49% +0.00%
SRTY ¹ DE 01 12:00 $35.75 DE 02 10:00 $35.12 $35.10 -0.19% -0.22%
SRTY ² DE 02 13:00 $34.96 DE 03 10:00 $34.27 $34.29 -0.21% -0.23%
AGQ DE 04 09:45 $42.03 (Not yet)
URTY ² DE 03 15:00 DE 04 11:00 $85.90 $86.52 (Not yet)

FRED: Finally got a ”sell” signal.  I saved a small amount of money by skipping this trade.

YHOO: Finally got a ”buy” signal.  Would have saved money if I had entered the trade properly and not bought so soon.

TZA: This trade failed to go through, apparently due to a momentary glitch at Schwab.  I tried manually buying it at the same price later that day, but the limit-order was not reached so I gave up on it.

AGQ: Bought at low of day!  Then it went lower the next day.

URTY ²: Not sure why this trade was late.  It seemed okay at the time, but now the model says I should have bought earlier.

New trading models

I finally finished a project that’s been on hold for months: I have refactored the trading models so the common code is pulled out into a separate file of macros.  This makes it much easier to just code up a new model when I think of something.  Since none of my current short-selling models seem to work very well, I’ve tried a whole bunch of new short models in the last two weeks — but none of them work well enough to use.  Here are two examples:

Momentum model

Short: Before 4pm, when
  • TRIX(50,2) < 0
  • TRIX(14,6) < 0
  • hourly close < SMA(200)-0.8*STDDEV(200)
  • This hour’s True Range > 7*ATR(15)
Cover: Before 4pm, when
  • TRIX(14,6) > 0
Stop: Updated at 4pm, use the lesser of
  • EMA(25)
  • Low_since_purchase plus 4*ATR(15)

Basically, we short when slow-TRIX is favorable, price is below the lower Bollinger band, and has just dropped by a significant amount.  We cover when quick-TRIX is unfavorable.  There is a fixed stop at EMA and a trailing stop that’s based on the Average True Range rather than a fixed percentage.

Results using TWM (2× leveraged inverse ETF):
2002‥2007+1.1%
2008+1.8%
2009-0.1%
2010-1.1%
2011+0.5%
2012-0.4%
2013-0.1%

This just isn’t very impressive.  In order to avoid losing money during 2002‥2007, I can make only 2% during 2008, when the market dropped 33% in a month!  It dropped 20% in 2011 but I get only 0.5%.

Staircase model

Short: Before 4pm, when
  • Each of the last five hours has had a lower high than the previous one
  • Price is below stop
Stop: Updated every hour, use high from two hours ago.

This model has the problem that Schwab doesn’t give me hourly highs, just high-of-day-so-far, so I would have to use barchart.com whose quotes are delayed by 20 minutes.  So actually implementing this thing would be difficult.

Results using TZA (3× leveraged inverse ETF):
2002‥2007-7.8%
2008+2.3%
2009+0.1%
2010-1.4%
2011-0.8%
2012-1.3%
2013-0.1%

I studied the chart for 2008 while constructing this model — and it does okay for that year only!  It doesn’t manage to make anything in 2011 and its long-term average is a net loss.  Useless.