sevenacorns 6 posts msg #101660 - Ignore sevenacorns |
7/15/2011 1:12:32 PM
I'm wondering if there is a way to run a filter a particular stock to see when it has triggered in the past, rather than running the filter for just a particular date (today or in the past)?
Thanks for any help on this.
Isaac
|
four 5,087 posts msg #101661 - Ignore four modified |
7/15/2011 1:39:19 PM
Information:
line 1 : Apple (aapl)
line 2 : LOGIC is X = 1 when rsi(2) < 30 and X = 0 when rsi(2) > 30
NOTE: The 1 in the filter is the number of days to check for the LOGIC. The COUNT checks each day as an individual event. A 1 or 0 is assigned.
line 3 : Draw x
line 4 : Draw line at rsi(2) = 30 for additional visual
See filter below:
|
sevenacorns 6 posts msg #101662 - Ignore sevenacorns |
7/15/2011 4:19:08 PM
Thanks for your input, but unless I just don't understand, this isn't what I was looking for.
What I'm interested in seeing is one of my filters run on just one stock, say AAPL, to see when the filter would have been triggered for this stock over the past year.
Thank you.
|
duke56468 683 posts msg #101663 - Ignore duke56468 |
7/15/2011 4:47:17 PM
Can you give the filter you are talking about. May not be that complicated to figure out if we know the filter.
|
sevenacorns 6 posts msg #101665 - Ignore sevenacorns |
7/15/2011 6:36:13 PM
Sure-
the filter has some general rules like market cap and price, and
And CCI(90) is greater than 50
And MACD Histogram (8/21,7) is greater than 0.0
Slow stochastic(33,5) %D crossed above 50 in the last 1 day
and price is more than 0.7% greater than close 1 day ago
Thanks, Isaac
|
Kevin_in_GA 4,599 posts msg #101667 - Ignore Kevin_in_GA |
7/15/2011 7:19:26 PM
And CCI(90) is greater than 50
And MACD Histogram (8/21,7) is greater than 0.0
Slow stochastic(33,5) %D crossed above 50 in the last 1 day
and price is more than 0.7% greater than close 1 day ago
look for whenever the trigger graph line shows a spike - that tells you when historically it occurred.
|
duke56468 683 posts msg #101668 - Ignore duke56468 |
7/15/2011 9:57:59 PM
Thanks Kevin........ I couldn't get that far, but I think he wants to apply it to a symlist and have it tell him how many times it occurred for that stock in the last (x) period. I'm not sure SF can do that.
|
Kevin_in_GA 4,599 posts msg #101671 - Ignore Kevin_in_GA |
7/16/2011 7:39:50 AM
Well, you could just replace the line "trigger above 0.5" with "watchlist(XYZ)" or "symlist(AAPL)", then look at the charts.
Beyond that I don't think SF code can do much more.
|
sevenacorns 6 posts msg #101673 - Ignore sevenacorns |
7/16/2011 11:17:14 AM
Thank you very much Kevin for the solution provided- this does what I was looking for, which basically is a visual way to analyze how a filter performs by looking at the trigger points on a stocks chart, rather than utilizing the backtests (which I find difficult considering all the variables).
Much appreciated.
Isaac in Seattle
|
sevenacorns 6 posts msg #101674 - Ignore sevenacorns |
7/16/2011 11:46:23 AM
Kevin-
How do I write the code for this trigger lookback for the following line-
[and CCI(77) has increased more than 15 in past 2 days]
Thank you for your time.
Isaac
|