Sunday, February 25, 2018

No trade this week; looking for the next one(s)

I am working with QuantGo data to find my next trade ideas. I made progress on importing the data I'm evaluating into a database using this toolset:



Python comes with a terrific feature in its CSV module: it can "sniff" the format of the CSV file in question and automagically figure out how to parse it:

with open('example.csv', 'rb') as csvfile:
    dialect = csv.Sniffer().sniff(csvfile.read(1024))
    csvfile.seek(0)
    reader = csv.reader(csvfile, dialect)
    # ... process CSV file contents here ..

I found SQLAlchemy to be well documented and a pleasure to use ...

Next more database design for auxiliary tables I will need to store the underlying values and the delta of the options, etc.

Also I found on a StackExchange site for quants a post on backtesting so I am trying Orats, but I'm not sure it can do what I want to do ...

More next week ...

Sunday, February 18, 2018

NDX trade wins AGAIN ... unfortunately now only available once per month

I exaggerated in my post from a couple of weeks ago: Nasdaq hasn't completely killed the golden goose, just 3/4 or 4/5 of it ...

The a.m. settlelment is still available Expiration Weeks (for the monthly options only) and Tastyworks even has a lovely UI clue available on this now:


So I put this on just before 10a.m. Thursday as normal and got from $1.35 to $1.77 in credit,
which is 15.6% to 21.5% ... I have been refusing to watch the /NQ futures to keep from being agitated when there's nothing whatever to be done about this trade once the Thursday session closes. (Assuming you don't want to try and buy or sell enough /NQ futures to cover the potential loss ... I considered this in a previous post, but I decided the trade was profitable enough without messing with this.)

But I couldn't resist peeking as I had the biggest trade of this type I've had on since I started using the Kelly Criterion: 25% of the account was at risk. The /NQ futures were above the NDX short call strike all night and into the morning and I thought the trade was dead, dead, dead ... but not so. The NDS (settlement price) was 6779.91. Whew.

So that's it for snooping /NQ ... This is 14 for 15 that I watched this or traded it, which is a 93.33% win rate ...

I need to find another one of these for the other 3 or 4 weeks of the month, so with that in mind I signed up for 6 more months of Quantgo, the data provider that provides access to a reasonable timeframe of data access for a not-awful price ($150/month for the 1-minute trade data that should be all I need to do research on other trades.)

One top candidate I'm going to be looking at: UVXY, a leveraged volativity ETF.

The Dumb Way of using Volatility one came out during the little down move we had early this month:


                RIP XIV and SVXY


These two (XIV was an ETN and SVXY an ETF) were short the front month /VX futures while being long the back month, which in some situations (like early this month) ... can cause the front month to skyrocket while the back month stays put. This is what apparently happened, because XIV went completely under (plug pulled by Credit Suisse, its underwriter for this ETN) ... and SVXY stayed in supposedly just because they didn't "rebalance" when they were supposed to be instead waited for the market to calm down.

That's the dumb way; the reasonable way that would have worked fabulously the last few years would have been just to sell a limited-risk call spread on UVXY (or buy one of the short ones) ... this certainly won the majority of the time the last 5 years, but I want to see exactly how often and how it behaves through weird periods like early this month and January 2016 ... does it lose 2 weeks in a row or more?

I'll have answers on this shortly .... more next week!


Sunday, February 11, 2018

Volatility too much for the TSLA trade: now 3 for 5

The TSLA trade failed last week, making it now 3 for 5. It's out of Kelly Criterion range for sure, now and I'm looking for an alternative.

The one I have for this coming week is the old standby NDX trade, since it's monthly option expiration. But for the following three weeks I need to figure something else out.

One possibility:

Its leveraged ETF is VXX, and I'm going to try both of them by backtesting on a dataset I can get from QuantGo:

They resell options and futures data for a pretty reasonable price. I used their service early 2017 when I was trying to develop an algorithm. I gave up on that but now could use this again to more quickly sort through different underlyings to narrow down candidates to test via monte carlo simulation ...

More next week ...

Saturday, February 3, 2018

Nasdaq killed my goose!

Here I was, about to go 13 for 14 on the NDX trade:

But I got this email just before the close on Thursday:

NDX Weekly PM-settlement Reminder


They (Nasdaq) changed the weekly options from A.M. Friday settlement to P.M. Friday, making a 4-hour (or less) trade into a 10-hour one, which makes all the difference. Especially this past Friday.

What I should have done (at the very least) would be to get up at market open and close the NDX positions. Instead I waited a little later and closed most of the ones I had on and only let one in my personal account (fortunately just a one-lot) go to expiration.

The really annoying part is that this would have in fact been a winner if a.m. settled, as NDS (the NDX settlement value, which is calculated anyway even if NDX isn't using it):

6,871.33

And I'd sold the 6870 put, so this would have been a full winner, again. Rats!


The real carnage in the market started later in the morning:




Fortunately the monthly NDX options are still a.m. settled, so I can still get this trade in 1 of every 4 or 5 weeks. But my plan was to do it every week and I'll have to find one or more substitutes.

That brings us to TSLA, which was 3 for 3 coming into Thursday If I want to do the Kelly Criterion analysis for this one I need to start gathering data, so: 

$0.32   14.6%  (on a $2.50 wide iron condor)
$0.57   29.5%
$0.59   30.9% 
$0.73   41.2%

... but the last one failed ... If I average these 4 I get $0.5525, or 28.3%. 

The Kelly Criterion for this at a 75% win rate is negative (i.e. "no bet!") But if I change the rate to 80%, it suggests you bet 9% of your account ...

More next week ...