Home                           

 Try Investor/RT             

 Investor/RT Tour           

 Getting Started              

 What's New                  

 Testimonials                 

  Q&A - Broken down by Topic . . .      Complete List of Questions - All Topics
     Charts and Technical Indicators      TPO Charts
     RTL: Scans, Signals, and Custom Indicators      Importing and Exporting
     Trading Systems and Backtesting      Schedules
     Quotepages, Portfolios and Custom Columns      Alarms / Alerts
     Data: Historical Data, the Database, and Data Services      User Variables (T# and V#)
     Custom Instruments: Spreads and Pairs      General / Miscellaneous
     Controls, Windows, and the Button Indicator      Autotrading
     Slide Shows      Product Line

 
Q&A Home

Investor/RT Answer
Answers to Common Questions

   

Question

How would I write a scan to pick out symbols based on a date or word pattern?
   

Answer

Text can be entered into any T# variable or the USERDATA quotepage column by typing the info into a quotepage cell.

Text can be entered into any T# variable or the USERDATA of any symbol using File: Import facility. Follow the instructions for import type "Current Quotes/Other Data".

You can also "set" text into a T# or user data by running a scan whose formula contains a SET command, e.g. SET(T#1, "some text");

Once data has been established in a text variable you can search for instruments having certain text patterns using a scan, e.g.:

T#1 == "*11/24/04*"

will find any instruments whose T#1variable contains the exact string 11/24/04 anywhere inside the text.

The * character in a pattern matches any string of 0 or more characters.

The ? character in a pattern matches any 1 character. Thus:

USERDATA = "*11/??/04*" will match any instruments having 11/??/04 in the user data field, ?? can be any two characters.