unomateo 1 posts msg #34689 - Ignore unomateo |
1/2/2005 5:43:18 PM
HI,
is it possible to add days to the offset, so I can see into the future, I think this will really help me?
Just kidding, seriously,
Is it possible to set an offset, something like "offset 30 days" and then create a column with the prices of the stocks 5 days after the offset to see the results?
Example:
Find stocks trading below 50
and p/e ratio below 20
and macd above 0.05
and macd 2 days ago below 0 for 5 days
and volume is above 50000
set{initial_price, price}
/*need column with prices 5 days after initial_price, basically offset of 25 days*/
add column initial_price
offset 30 days
|
xplorer 257 posts msg #34700 - Ignore xplorer |
1/2/2005 9:50:20 PM
This was from a previous forum .... but I am sure you can adapt to your filter:
...click on it , and you'll see what you are looking for.... its not a pretty way to do it ...but it will give you what you are looking for... the way it is written is to show the screen from 118 days ago ,,, then the next 5 days. I think it is the only true way to backtest ... without the bias of the market sentiment of TODAY ...
|
cegis 235 posts msg #34736 - Ignore cegis |
1/4/2005 2:18:59 PM
Look for my post "Technique: Calculate returns for any period" (or something very simmilar). (A forum search on 'cegis technique' should show it prettu near the top, I think...) It describes how to do what you are looking for. While there's nothing wrong with the prior example, if you're looking for the next five day's data, it might make more sense to use 5 days ago, ..., down to 1 day ago, then use offset to look at different periods. This is all explained in my prior post.
HTH,
C
|