Multiple Symbol list Script values for historical data

I have tried using the Watchlist and Scanning Manager to return the value using a script within a 10 year range and it doesn’t seem to work.
Scanning Manager only returned the date for the 1st occurrence and Watchlist only returned at most 2 occurrences for a ticker but ShowMe showed many occurrences for that ticker.
For example, if I have a list of multiple tickers that are imported from a csv and want to find how many times a condition occurred as a back test
such as: BARSTRUE(MA(STYLE=Exponential, BARS=10, CALC=Close) CrossesAbove MA(STYLE=Exponential, CALC=Close, BARS=20));
So each ticker would show a value of how many times the faster MA crossed above the slower MA for a 10 year period for daily historical data.
Is there a way to achieve this?

Hi Dan,

The BarsTrue() function is usefull if there is a specific look back period you want to check. However in your example you are wanting to check the entire history for each code, which varies from code to code.

In this scenario i’d suggest using the ACC() function instead.

Using the Moving Averages in your example the updated script would look like this…

V1 = MA(BARS=10, STYLE=Exponential) CrossesAbove MA(BARS=20, STYLE=Exponential) ;

Add the above script to a Watchlist and you should see the result you are after.

Thanks Mathew. This is quite helpful.

So I went further and was creating multiple conditions assigned to v1 in relation to this question and not sure why a number of them did not return a value and some others returned 0 for the ACC() function. ARNC and NLSN did not return a value for the following script:


COND1 = CLOSE() < MA(STYLE=Exponential, BARS=30, CALC=Close) ;

COND2 = VX > 20;

COND3 = CLOSE() CrossesBelow BB(BARS=30).LowerLine;

COND4 = (RSI(BARS=30) > 25) and (RSI(BARS=30) < 55);

V1 = COND1 and COND2 and COND3 and COND4;


Hi Dan,

The script looks fine and is working ok here on both those codes (ARNC returns 7 and NLSN returns 19). I believe both of those codes recently moved to the NYSE so you may want to open a chart for each to make sure the full history is there. If it is not run through Option 2 listed on the following article…

Hi Mathew. I don't have NYSE and ARNC only comes up in US Equities andis only pulling as of 2016, 33 bars. I have downloaded the history for US Equities, ARNC itself and end of day data. It is showing last downloaded date of March 19, 2019. And when apply the logic in ShowBar (without ACC()), it does create the signal 7 times as you have stated but the Test column where I have my script shows nothing. Also, not sure why tickers show up twice. I have attached screenshots. Thanks.



Hi Dan,

I am unable to repeat the issue on my system here. Can you please send me the workbook containing the Watchlist in your screen shot an i will test it here (it maybe some combination of settings at work).

Workbook files by default are stored here: My Documents - Optuma - Local - Workbooks

Please email the workbook file to [email protected]

I removed the duplicates and not sure how why they were duplicated, but it now works.

I see a value returned for all the tickers. Thanks for your help.