StockFetcher Forums · General Discussion · Net change for days after filter<< >>Post Follow-up
fotchstecker
314 posts
msg #161910
Ignore fotchstecker
modified
7/28/2025 11:33:19 AM

Can't remember how to do this...

Is there a way to calculate a filtered symbol's future net change or % change for x days after the filter result? I just want to see how the stock did for x days after the signal when reviewing past scans on various dates.

thanks.



xarlor
609 posts
msg #161912
Ignore xarlor
7/29/2025 10:21:22 AM

This example shows you the performance 15 days after a golden cross. Is this along the lines you're looking for?

Fetcher[
/* Example signal: Golden cross */
ma(50) 30 days ago crossed above ma(200) 30 days ago

/* Future performance */
set{futureClose, close 15 days ago}
set{signalClose, close 30 days ago}
set{gain, futureClose - signalClose}
set{pctGain, gain / signalClose}
add column pctGain
]



fotchstecker
314 posts
msg #161913
Ignore fotchstecker
7/29/2025 2:55:17 PM

Thanks,Xarlor. I think so. So does this require you to offset your primary filter?

xarlor
609 posts
msg #161917
Ignore xarlor
7/29/2025 10:05:26 PM

Yes, offset it by putting in "X days ago" in the criteria, as per the example above.
Change signalClose to that same X.
Change futureClose to the number of days after your criteria you want to backtest.

StockFetcher Forums · General Discussion · Net change for days after filter<< >>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.