Friday 29 June 2012

exchange traces

Through making the NYSE, NASDAQ and LSE traces work, I have spotted significant differences in the way the separate exchanges seem to operate. The same trace formulae are being run against each exchange, the combinations are full and complete and so there are no other options here, but the different way each exchange reacts to these formulae is startling.

The tweets for the traces are the resultant per day triggers of formulae with the best success coefficients. It is the success coefficients that are different for each of the exchanges which needed to be updated for NYSE and NASDAQ because the LSE one, used in the first instance,  produced zero results.


Wednesday 27 June 2012

Tweet recap and update

The content of the tweets has changed a little over the last 3 months and needs a little explanation.

Companies that have been triggered by a formula are tweeted twice a day, just after market close and analysis, and 12 hours later, to ensure that the most current companies are tweeted at the most current time.
The Auto tweets API allows only 5 companies to be tweeted. If you would like to see the full list, email.

The initial beta formulae, crafted by hand over weeks and months, are still being tweeted. These are designated with titles such as LSE_b4. These are good, and worth consideration.

The trace tweets have titles such as LSE_trace and if you do nothing else, consider these. These are the companies that have had specific bespoke algorithms run against them (around 300,000 in total) to obtain the best matches and if these trigger then we have a good chance.
oasis is about two thirds into the completion of the full trace analysis (8 weeks processing in total, 24 hours per day, 5 weeks in), but as each company completes analysis the trace formulae are put onto the trigger list for that company.
I am currently testing the traces for the NYSE and NASDAQ at the moment.

Tweets that say 'no companies found for analysis'/'no co' mean that the trigger did not return any companies following the specific formula for that day, and just contains a link back to here.

The tweets include a link to Google Finance for the company being tweeted.


And to recap on the analysis techniques, these currently are:
1. trace - combination analysis and bespoke company formula - explanation here
2. beta - hand crafted formula - explanation here
3. Candlesticks - explanation here


And also, currently on my list of things to do, in no particular order, are:
1. Add FX into exchanges
2. Complete Candlestick analysis
3. Link into RNS for LSE
4. NYSE and NASDAQ traces

SIE

Here's a coincidence. SIE has just come up on the trace tweets for today.

(Along with WSG, PDX, AGQ and AGOL - AGOL we have seen before)

Sunday 24 June 2012

initial Candlestick analysis


Below is a section of the report of my initial analysis of the Candlestick processing. Currently the report only includes elemental and relational aspect of Candlesticks - the inclusion of the trend, or in fact any aspect to the usual indicators such as rsi, adx, vi or stochastics, etc is being analysed at the moment.

The columns are - LSE company (my tests are being carried out on the London exchange LSE, I will be adding NYSE and NASDAQ very shortly), code combinations of elements and relationals, number of time this has occurred in the last 5 years with a subsequent 5 day rise of over 11.5%, and the number of times in total this combination has occurred for this company.

The report is sorted by the relationship between number of times triggered and producing an 11.5% increase, and the total number of times triggered


-------------------------------------------------------
....


T27  uuuE004F004G004R018S018  5 5
SIE  uuuE002F002G002R008S006  4 4
SIE    uuuE002F002G002R008S008  4 4
SAUS uduE002F002G002R014S008  4 4
SER   uuuE004F004G001R017S017  4 4
AAZ    uuuE004F004G004R012S012  3 3
H50E   duuE002F002G002R008S001  3 3
RUKS uddE003F002G002R014S002  3 3
BOR uduE003F003G003R013S013  3 3
TDK uuuE002F002G002R014S014  3 3
OPG uuuE003F002G003R013S001  3 3
T17   uuuE004F004G004R018S019  3 3
SIE    uuuE002F002G002R013S014  3 3
T17   uuuE004F004G004R019S018  3 3
XEL  uuuE002F002G002R013S013  3 3
SAUS  uddE002F002G002R013S009  3 3
BEM uuuE002F004G004R012S012  3 3
FRR  dddE002F002G002R014S009 3 3
EME uudE003F002G003R013S013  2 2
SAUS  uuuE004F003G003R001S002  2 2
SER  uuuE004F001G004R017S017  2 2
AFC  dddE002F002G007R002S021 2 2
COP uudE004F004G004R017S019  2 2
EME uuuE003F004G004R012S003  2 2
CAZA  uuuE003F003G002R001S002  2 2
RICI  uudE003F003G006R001S014  2 2

.....
--------------------------------------------------------


So lets take the first sensible line - SIE and 'uuuE002F002G002R008S006'

(T27, even though we get daily data downloaded from the LSE, T27 is neither listed in LSE Shares or on Google Finance, so do not really know what this is)


I believe the Candlestick code combinations like 'uuuE002F002G002R008S006', or part thereof, have been noticed and have been given names - if we delve a little deeper, we notice patterns emerging from the SIE record, for example for SIE, all the combinations for the above report section all start with 'uuuE002F002G002' and the pattern changes only after the R code - you can probably guess what each 3 letter code means, but what will be less obvious is how each 3 letter code relates to the Candlestick formulae.

What I can say at this point is that the codes for each company are now being analysed Candlestick wise and compared with the current day codes, any that follow the rule greater than 90% of the time will be tweeted.

Also, there are two other aspects to the work on Candlesticks that have spawned separate analysis
1. Not only has this analysis given the 11.5% risers, but also the codes to follow for each company with respect to decliners - ie analysis on sells
2. A serious and complex link into the traces that are happening at the moment - Candlesticks can be thought of as another indicator, rather than a separate entity


I think I'll call 'uuuE002F002G002'... 'two thumbs'




Wednesday 20 June 2012

trace update

Quick update on the traces being run at the moment - LSE:762:41.5m, NYSE:471:7.7m and NASDAQ:655:4.6m
(exchange:number of companies traced:number of records)

Revised estimate to completion is now 8 weeks, we have had 4.5

the 22 Candlestick relational formulae


And for interest, following are the 22 definitive relational options for Candlesticks

xxx is the current period, yyy is the previous period, aaa is open price and bbb is the close price (specifically for the relational formulae for 2 periods both of which have the close greater than the open, aaa and bbb will be different for the other combinations of close and open price)

Each statement is taken separately and is period mutually exclusive, so as an example the first statement 'and xxx.f_low>= yyy.f_high' means 'if todays low is greater than or equal to yesterdays high' - with this statement one does not need to go any further because if this is true then we already know all the other relational relationships, ie that today's close, open and high will also be greater than or equal to yesterday's high

Below is also a screen shot of the logic by which one can get to the formulae, and should help to make some sense of the formulae

-=-=-=-=-=-=-=-=-=

and xxx.f_low >= yyy.f_high

and xxx.f_low < yyy.f_high and xxx.f_high < yyy.f_low

and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low < yyy.f_low and xxx.aaa >= yyy.aaa and xxx.aaa >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low < yyy.f_low and xxx.aaa >= yyy.aaa and xxx.aaa < yyy.bbb and xxx.bbb >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low < yyy.f_low and xxx.aaa >= yyy.aaa and xxx.aaa < yyy.bbb and xxx.bbb < yyy.bbb

and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low < yyy.f_low and xxx.aaa < yyy.aaa and xxx.aaa >= yyy.f_low and xxx.bbb >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low < yyy.f_low and xxx.aaa < yyy.aaa and xxx.aaa >= yyy.f_low and xxx.bbb < yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low < yyy.f_low and xxx.aaa < yyy.aaa and xxx.aaa < yyy.f_low and xxx.bbb >= yyy.f_low and xxx.bbb >= yyy.aaa and xxx.bbb >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low < yyy.f_low and xxx.aaa < yyy.aaa and xxx.aaa < yyy.f_low and xxx.bbb >= yyy.f_low and xxx.bbb >= yyy.aaa and xxx.bbb < yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low < yyy.f_low and xxx.aaa < yyy.aaa and xxx.aaa < yyy.f_low and xxx.bbb >= yyy.f_low and xxx.bbb < yyy.aaa
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low < yyy.f_low and xxx.aaa < yyy.aaa and xxx.aaa < yyy.f_low and xxx.bbb < yyy.f_low

and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.aaa and xxx.aaa >= yyy.aaa and xxx.bbb >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.aaa and xxx.aaa >= yyy.aaa and xxx.bbb < yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.aaa and xxx.aaa < yyy.aaa and xxx.bbb >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.aaa and xxx.aaa < yyy.aaa and xxx.bbb < yyy.bbb

and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.f_low and xxx.aaa >= yyy.aaa and xxx.aaa >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.f_low and xxx.aaa >= yyy.aaa and xxx.aaa < yyy.bbb and xxx.bbb >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.f_low and xxx.aaa >= yyy.aaa and xxx.aaa < yyy.bbb and xxx.bbb < yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.f_low and xxx.aaa < yyy.aaa and xxx.bbb >= yyy.aaa and xxx.bbb >= yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.f_low and xxx.aaa < yyy.aaa and xxx.bbb >= yyy.aaa and xxx.bbb < yyy.bbb
and xxx.f_low < yyy.f_high and xxx.f_high >= yyy.f_low and xxx.f_low >= yyy.f_low and xxx.aaa < yyy.aaa and xxx.bbb < yyy.aaa

-=-=-=-=-=-=-=-



So what can we do with these ?

We have xxx and yyy because we have 3 periods to combine in the relational process, today, yesterday and the day before yesterday - that is for the relationship between today and yesterday xxx and yyy will be today and yesterday, and the relationship between yesterday and the day before, xxx and yyy will be yesterday and the day before - aaa and bbb are the dependent on if close is higher than open, but are either open or close prices.

What we can say is that for today and yesterday we can take the first statement and calculate the success coefficient (how well it conforms to wealth increase) and then we can combine with all of these same statements for the periods 'yesterday and the day before', again to give separate success coefficients, and then run the statements with the highest success coefficients on a daily basis, if triggered then tweet and /or combine with the current traces for further analysis

The statements are also designed around database sql statements and so plug directly into the Candlestick trace engine and hence the 'and' at the start of each sentence

This is purely for the relational aspect of Candlesticks, we also need to add the intra period and trend formulae on top of this

Friday 15 June 2012

candlesticks redux

Whilst the traces are progressing, I have focused on the processing of Candlesticks.

With an eye on what is assuredly a method that has gone through a lot of development over many years, I have re-engineered and carried out a data analysis on Candlesticks. There appears to be 3 aspects that are relevant:

1. Relational
This is the relationship between periods and states things like 'high today is higher than the high yesterday'


2. Elemental
This is within the period and states things like 'the close is very close to the high and the (close - open) is 0.005 of (high - low) 


3. Trend
Allocating trends on top of the previous 1 and 2, ie saying things like 'on a bullish trend and if todays high is greater than yesterday's high'


If we take all possible combinations of the above we get approximately 43 factorial different combinations of possible formulae. This is 6 to the power 52 - and wrong. It is wrong because we end up with statements like 'if todays high is less than todays low' - so we need to eliminate all combinations that do not make sense. This exercise for the Relational section gives us 22 different options, Elemental is 3, and Trend is 2.

The permutations here now (rather than combinations as per the traces), gives 22 x 22 x 4 x 3 different correct permutations: 5,808 - the 4 and the 3 are one plus Elemental and Trend - and compared to the 300,000 odd combinations being currently calculated for each company via the traces.

Also needing to be taken into consideration is if the close for a period (within each period) is higher or lower than the period's open - there being 4 options - the options of current and previous period close and open - but still 5,808 options per combination.

What these 5,808 permutations give us is every single possible combination of states between 3 periods and prices of open, close, high and low.

And so the Candlestick trace engine is taking shape. When completed and run we will have success indicators for every single type of Candlestick combination for every company. We can then match these Candlestick traces to current period indicators, giving us the same type of information as the traces.

What I am expecting to see is that the combinations with the best success coefficients will have been named. I have done this re-engineering because the first pass at Candlestick analysis has given some random results and I need to know that I have covered all bases, in this case all possible permutations - it also makes certain that I havent missed anything.

Sunday 10 June 2012

GBP, BVC, BDEV, EMIS, IPO

GBP on the LSE is in, BVC, BDEV, EMIS and IPO are in and repeated. AMER is now out of the trace formulae as is OPTS.

Having done analysis on the traces, what is happening is that different formulae are being triggered on subsequent days, giving a range of days that companies follow triggers. This reinforces the notion that all the formulae that state when a stock is supposed to rise, when added together, give no companies - and follows that the number and percentages for companies being returned for formulae that contain more than 7 elements drops dramatically.

What does this mean ? It means I will be watching all the above companies over the next 5 days.

The number of companies and trace records currently are -  LSE:491:26m, NYSE:144:2.7m, NASDAQ:257:1.7m - getting there slowly

Thursday 7 June 2012

EMIS, BVC, BDEV, AMER and something called AUP3

The above triggered today, AMER is third day running but as we know we have already had a 28% increase on the first day so interesting to know what happens tomorrow, now watching EMIS, BVC and BDEV. AUP3 is a peculiar one and is 'ETFS FOREIGN EXCHANGE LIMITED ETFS 3X LONG AUD SHORT GBP' - does this mean anything to anyone ? cos by all accounts it should go up in the next 5 days by 11.5%.

Not sure you have noticed but the trace calculations for all exchanges is carrying on 24 hours a day, one company about every 2 hours, 3 exchanges in parallel, and I am only up to about the A's on LSE, NYSE and B's on the NASDAQ. At the start I had been testing by tracing random companies and so the reason why we are getting companies starting with different letters for the LSE. It also seems that the traced companies for the NYSE and NASDAQ have not hit any companies that trigger on the specific day as yet (last three days). I am hoping this changes as more companies are traced, in fact I am quite surprised at the number being returned by the LSE traces, the auto tweets tweet the top 5 results for LSE_trace; today oasis returned 7, the missing ones being OPTS (again) and IPO (again), these repeats seem also to be interesting and I am keeping a close watch on them. We almost have a full set of companies from all exchanges that have been traced and start with 'A'... at least its a start, and trading only companies that start with 'A's seems just as limiting as trading only oilies, or minies.
Also, for information, the number of trace records currently for LSE after 451 companies is 24,069,113; this is about a fifth of the way through LSE. I am expecting a similar total number for NYSE and NASDAQ; NYSE currently stands at 1,055,174 records for 59 companies traced and for the NASDAQ, 700,837 records for 111 companies traced.

Also, by my calculations the complete trace for the three exchanges is going to take about 4 months to complete running 24 hours a day on my system, and my system is not small. Anyone with a Exadata or similar want to share resources ?

Wednesday 6 June 2012

IPO, EMIS, BVC, BDEV and AMER

AMER up again today, along with others to watch, IPO, EMIS, BVC and BDEV on the LSE

NYSE and NASDAQ calculating

Tuesday 5 June 2012

OPTS, AMER, AGOL and BMR

After days compiling the trace combination results, we have our first set of companies for the LSE_trace, and have been tweeted under LSE_trace - OPTS, AMER, AGOL and BMR. I will be following these with particular care over the next 5 days.

To confirm the process to pick these companies: the trace reporting process chooses those companies that have been triggered with a combination of elements (single trigger criteria) that have triggered more than 3 times over the past 1.5 years, with an individual triggering percentage increase over the subsequent 5 days of more than 11.5%, and each trigger is 90% (rather than 85% previously) of the maximum percentage increase over the same 5 days, that is, the triggering momentum is large.

This process is running at the moment for the NYSE and NASDAQ.

Friday 1 June 2012

tell us, what do all these traces give me ?

I am getting some solid information on the relevant triggers for each separate company that have given 11.5% increases over 5 days.

oasis can now take the formulae giving more than an 85% average increase relative to the maximum percentage, and greater than 11.5% on every individual date, for a specific company and if triggered again today, twitter the results under the banner 'exchange_trace', that is for the London LSE it will be 'LSE_trace', NYSE will be 'NYSE_trace', and 'NASDAQ_trace' for the... NASDAQ.

Also the auto tweet system only tweets the top 5 most relevant companies each 'auto-tweet' - if you are interested in the full listing per day then email me.

twitter feed is:

https://twitter.com/#!/spacecadet99999

I am in the process of adding FX exchange, and also continuing work on Candlestick patterns, and RNS analysis (I have now 167 days worth of RNS company reporting data)