SQL Script: 52 week max "Horizontal Distance"

9 views
Skip to first unread message

Dan Bikle

unread,
Jun 5, 2014, 8:06:23 PM6/5/14
to bikl...@googlegroups.com
People,

Our friend Zvi suggested we look at a feature he calls "Horizontal Distance".

I wrote a simple SQL script to calculate horiz_dist_mx52
which is the number of days since the last 52 week high.

Then I looked for evidence of a simple relationship between horiz_dist_mx52
and 1 day pct-gain.

I found that when horiz_dist_mx52 is abnornally small,
then pct-gain is below average.

Currently today, 2014-06-05, horiz_dist_mx52 is abnormally small,
so if we follow horiz_dist_mx52 as an indicator,
then I see that as a short term bearish indication.

Also I found that when horiz_dist_mx52 is abnormally large,
then pct-gain is above average.

I noticed that horiz_dist_mx52 is rarely abnormally large.

The last time that happened was 2009-10-01

You will find the script here:

https://github.com/danbikle/spy611scripts/blob/master/script/horiz.sql

You will find output from the script here:

https://github.com/danbikle/spy611scripts/blob/master/script/horiz.txt

Dan

Reply all
Reply to author
Forward
0 new messages