Navigation: Trading Your System >

Daily Setups Scan





While not as simple as just running your system and generating an Order List, the use of a daily setups scan has several advantages:

the output is a scan window, which can more easily be saved to a format such as CSV that external automation software can read

you have total control over the contents of the output

The example script mr_sample_scan.rts is an adaptation of the mr_sample.rts long/short strategy pair to show how a daily setups scan could be used in live trading:

The key changes that were made to convert the original example script into this scan script are:

The Import Section has been modified to import only a year of data for the current Russell 3000 components, which is much quicker to use as a daily process than importing the full history with delisted symbols

A ScanSettings Section has been added to specify that this data file be used for the scan and that it is run for only the most recent bar

The long and short EntrySetup formulas have been moved into the Data Section

The MaxSetups and SecupScore formulas have been converted to data items using the #Rank breadth function

The EntryLimit formulas were already calculated in the data section so these are simply used as-is

A Scan Section has been added to select the highest ranked candidates for each strategy and output their ranks and limit prices

After running the import and then the scan, and then sorting the columns by long rank and then short rank, the following is output after the close of 7/10/2020:

Though up to 10 positions per side are allowed, it appears that only 4 stocks met the LongSetup criteria, while more than 10 met the ShortSetup criteria.

In the original mr_sample system, the daily per-strategy cap on the number of new orders to place also accounted for the number of positions currently open. When using the daily setup scan technique, this cannot be done automatically. For example, if you already had 5 short positions open, you would have to either manually remove the last 5 rows from the above output, or temporarily change your short max positions parameter to 5 and re-run the scan.

Similarly, the daily setup scan approach cannot be used to tell you which currently open positions need to be exited. For that purpose, see the next topic: Test Output Scan.





Copyright © 2020-2024 Systematic Solutions, LLC