/**
* stateTableCnt - # of times this state occurs
* StateTablePriceChangeTotal - sum of all price changes for this state
* using the combination of the 2 tables we get the average price change for the state.
* using the average price we get the action: buy (> 1.0) or sell (< 1.0)
* stateTableTransition - allows us to see where this state may go next.
*/

/* this is where back testing takes place */
if (dates.get(ix).compareTo("2017") > 0) {
// just work on data from 2017 and beyond.

int ixx = ix + daysOut + 2;
// go out at least 2 days so we don't test states that have
// already been recorded. AVOID THE LOOK-AHEAD PROBLEM.
if (ixx < dates.size()) {
// may get an out of bounds array exception; so test for it.
resultState = buildResultState(dclose, fasterMA, middleMA, slowerMA, ix);

Disclaimer

Past Performance Is No Guarantee of Future Results

This blog is for informational use only. I do not recommend buying or selling any financial instrument.

This is not investment advice!

None of the information or opinions expressed in this blog constitutes a solicitation for the purchase or sale of any security or other instrument.

Any purchase or sale activity in any securities or other instrument should be based upon your own analysis and conclusions.

Followers

How

Update on October 18 2017 - I added weighting to the methods that were found to most successful. Success is measured by how many time the method was most likely best during back-testing.

Updated on July 21, 2017 -

The scale is from 4 buy/sell indicators over the next 10 days

Using an artificial intelligence algorithm (RandomForest classifier from the WEKA libraries ) I am estimating price change indicators for ETFs. The algorithm is based on pattern matching price changes relative to the ETF's price change, its RSI and other related moving algorithm indicators.

During US trading hours I post Index estimates through out the day at McVerry Report