StockFetcher Forums · General Discussion · OR function - help with TheRumpledOnes code<< >>Post Follow-up
cire0015
6 posts
msg #141406
Ignore cire0015
1/26/2018 9:01:18 AM

Hello all,

Grateful for any help. I am coding a system where stocks will be returned if they have moved up 100% or more at any point in the last 56 days.

I am trying to use the set theory OR function as described previously by TheRumpledOne to code a filter as follows, the idea being that if a stock has moved up more than 70% in the last x amount of days it will be returned and I can then go through the list manually.

Can anyone tell me what the issue is here and why the following isn't working?

-----

set{A, count(close is more than 70% above close 1 day ago, 1)}
set{B, count(close is more than 70% above close 3 days ago, 1)}
set{c, count(close is more than 70% above close 5 days ago, 1)}
set{d, count(close is more than 70% above close 7 days ago, 1)}
set{e, count(close is more than 70% above close 9 days ago, 1)}
set{f, count(close is more than 70% above close 11 days ago, 1)}
set{g, count(close is more than 70% above close 13 days ago, 1)}
set{h, count(close is more than 70% above close 15 days ago, 1)}
set{i, count(close is more than 70% above close 17 days ago, 1)}
set{j, count(close is more than 70% above close 19 days ago, 1)}
set{k, count(close is more than 70% above close 21 days ago, 1)}
set{l, count(close is more than 70% above close 23 days ago, 1)}
set{m, count(close is more than 70% above close 25 days ago, 1)}
set{n, count(close is more than 70% above close 27 days ago, 1)}
set{o, count(close is more than 70% above close 29 days ago, 1)}
set{p, count(close is more than 70% above close 31 days ago, 1)}
set{q, count(close is more than 70% above close 33 days ago, 1)}
set{u, count(close is more than 70% above close 35 days ago, 1)}
set{r, count(close is more than 70% above close 37 days ago, 1)}
set{s, count(close is more than 70% above close 39 days ago, 1)}
set{t, count(close is more than 70% above close 41 days ago, 1)}
set{u, count(close is more than 70% above close 43 days ago, 1)}
set{v, count(close is more than 70% above close 45 days ago, 1)}
set{w, count(close is more than 70% above close 47 days ago, 1)}
set{x, count(close is more than 70% above close 51 days ago, 1)}
set{y, count(close is more than 70% above close 55 days ago, 1)}

set{OR1, A + B + c + d + e + f + g + h + i + j + k + l + m + n + o + p + q + r + s + t + u + v + w + x + y} show stocks where OR1 above 0]

----
Many thanks...
Eric

graftonian
1,089 posts
msg #141407
Ignore graftonian
1/26/2018 10:30:23 AM

only one math statement is allowed, so you need:
set{or1, a+b}
set{or2, or1+c}
set{or3,or2+d}
and so on.................

StockFetcher Forums · General Discussion · OR function - help with TheRumpledOnes code<< >>Post Follow-up

*** Disclaimer *** StockFetcher.com does not endorse or suggest any of the securities which are returned in any of the searches or filters. They are provided purely for informational and research purposes. StockFetcher.com does not recommend particular securities. StockFetcher.com, Vestyl Software, L.L.C. and involved content providers shall not be liable for any errors or delays in the content, or for any actions taken based on the content.


Copyright 2022 - Vestyl Software L.L.C.Terms of Service | License | Questions or comments? Contact Us
EOD Data sources: DDFPlus & CSI Data Quotes delayed during active market hours. Delay times are at least 15 mins for NASDAQ, 20 mins for NYSE and Amex. Delayed intraday data provided by DDFPlus


This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.