StockFetcher Forums · Filter Exchange · Question about the LAG wording<< >>Post Follow-up
marine2
829 posts
msg #65863
Ignore marine2
8/5/2008 10:00:00 PM

Does the word lag still applicable in our filters? I haven't tried it in a long time and when I tried it recently I didn't see any affect. If it doesn't work, what verbiage can I use to back up the result in the filter by X many days. Example maybe i want the result to happen 2 days before it really happens etc.

guru_trader
485 posts
msg #65899
Ignore guru_trader
modified
8/6/2008 4:31:03 PM

i never use lag, but how about using ...

Fetcher[
2 days ago
]



post part of your filter so we can help

marine2
829 posts
msg #65917
Ignore marine2
8/7/2008 12:11:44 AM

Guru Trader, this is a simple filter but still showing what I am talking about here where i want to back up the results by X amount of days to truly catch the trigger point better.

and price is above 4
and macd histogram is crossing above 0 2 days ago

I have tried it using 2 days shown here and 4 days ago, and 1 week ago but I still get the same results. That being where it gives me the results as the macd histogram actually crosses the 0 line. I want it to back up so many days and show it a hair earlier. I hope I have been clear on what I am trying to achieve. I liked your thought on the "2 days ago" try but it didnt seem to work even though the debug status all looked "ok".

Maybe there's another expression that can create what I am striving for? Your help and others is always appreciated. Thank you.

ZXenigma
7 posts
msg #65926
Ignore ZXenigma
8/7/2008 3:45:19 AM

I found this regarding lag.

http://forums.stockfetcher.com/sfforums/?q=view&fid=1007&tid=24007&qrid=

I have a suspicion that the word lag only applys to certain functions. So it may not work with "crossing above". Didn't seem to work when i was trying to do something similar with MA's

Good luck


guru_trader
485 posts
msg #65928
Ignore guru_trader
modified
8/7/2008 6:30:19 AM

Here you go ...

Fetcher[
/* Basic Criteria */
and not otcbb
and avgvol(20) > 543210
and close > 4
and chart-length is 30 days

/* Draw MACD Histogram */
and draw macd histogram

/* Locate points in time where MACD Histogram crossed above 0 */
and set{macd_crossed_above, count(macd histogram crossed above 0, 1)}
and add column macd_crossed_above
and draw macd_crossed_above

/* Count days since the MACD Histogram crossed above 0 */
and set{days_since_cross, days(macd histogram crossed above 0, 100)}
and add column days_since_cross
and draw days_since_cross

/* Select for stocks where days since the MACD Histogram crossed above 0 = 2 days ago */
and days_since_cross equals 2
]



chetron
2,817 posts
msg #65931
Ignore chetron
modified
8/7/2008 7:05:23 AM

or maybe ....

i think you just need to place the " day ago" in the proper locale. imho
you want the histogram 2 day ago, not the 0?

Fetcher[


and price is above 4
and macd histogram 2 days ago is crossing above 0

]



StockFetcher Forums · Filter Exchange · Question about the LAG wording<< >>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 2016 - 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