Building your
own OpScan formulas can save you endless amounts of time in searching
for trades that meet your own personal trading criteria.
An overview
of the elements of an OpScan formula can be found in the OpScan
tutorial. It is suggested that you become familiar with the
different parts of OpScan formulas prior to building your own.
OpScan has
a set of specifically defined parameters and operators that must
be used when creating formulas. For your convenience, feel free
to print lists using the links below:
While writing
OpScan formulas, use the "Test Syntax" button to make
sure the formula is being written in the proper language and
structure that OpScan will understand. A "Formula is valid" message
will appear when the formula is written in acceptable terms.
If a mistake has been made, "Formula is invalid" will
appear with an explanation describing the deficiency - the position
of the error identified by a flashing "cursor".
Now let's proceed
to the formula writing!
Writing
the "Pick" line formulae
The "Pick" line
is the most critical element of the OpScan formula as it defines
the criteria of the options for which you are searching. Writing
the formula for the "Pick" line is much easier when
you know precisely what you want to find.
Tip: Try
writing a sentence or two that specifically describes the criteria
for which you wish to search before you attempt to create the "Pick" line
formula.
If you can
explain in simple terms exactly what you wish to find, transfering
the information into a mathematical formula is much easier. Once
the criteria is written down, you can start breaking down the
explanation into sections and then create a mathematical formula
using the OpScan parameters and operators for the OpScan search
engine.
Example: I
want to trade stocks in the price range of $20-$50 dollars.
I am looking for "calendar spread" candidates which
have 15% higher volatility in the near term options that I
will be selling over the longer term options that I will be
buying. To ensure liquidity, I want to make sure at least $500,000
dollars are being traded in the options each day.
Now that we
have a written explantion of what we wish to find, we can start
creating the actual mathematical formula by transfering each
sentence into mathematical terms.
Sentence
1: I want to trade stocks in the price range of
$20-$50 dollars.
Mathematical
Formula: LASTU>20 AND LASTU<50
Sentence
2: I am
looking for "calendar spread" candidates which
have 15% higher volatility in the near term options that
I will be selling over the longer term options that I will
be buying.
Mathematical
Formula: IV1>1.15*IV3
Sentence
3: To ensure liquidity, I want to make sure at least
$500,000 dollars are being traded in the options each day.
Mathematical
Formula: ATVOL$(5)>500
Now that we
have transferred each sentence into mathematical formulae, we
can combine them into one string for the OpScan "Pick" line
formula. We will use a comma followed by a space to seperate
each individual criterion that has been defined. The comma acts
as an "and" for searching purposes which designates
that each subset of criteria must be met before a security is
included in the OpScan report.
Pick
Line Formulae: LASTU>20 AND LASTU<50, IV1>1.15*IV3,
ATVOL$(5)>500
Now wasn't
that easy? By first writing down the description of our search
criteria, it was much easier to transfer the information into
mathematical formulae. Sentences 2 and 3 contain variables that
have been arbitrarily chosen for the purpose of explanation and
could have been written with a slightly different appeal. In
Sentence 2, we could have used IV1 vs. IV2 or IV2 vs. IV3 however
IV1 vs. IV3 was chosen as it identifies the largest time differential.
Sentence 3 contains a variable between the parenthisis for the
number of days used to calculate the average ATVOL$(n).
A 5 day average was used for explanation purposes; however, "n" allows
for any number between 1-20.
Writing
the "Sort" line formula
The "Sort" line
provides the basis for arranging the output in the OpScan report.
A formula is used and will typically relate to your search criteria.
In the example above we may choose to view the output in order
of the underlying stock price or average daily dollar volume
of options traded. However, since we are specifically looking
for a difference in IV (implied volatility) between 2 expiration
months, that is the basis that we will use for arranging the
output on the OpScan report. Write a simple sentence explaining
how you wou like to view the output before attempting to write
the "Sort"line formula.
Sentence: I
want to sort the output by the actual difference in implied
volatilities between the 2 expiration months.
Mathematical
Formula: IV1-IV3
The
formula will subtract the longer term's IV from the shorter term's
IV and result in the actual difference between the 2 expiration
months IVs. The output will then be displayed with the largest
differential at the top of the list in descending order. Some
variations of "Sort" line formulas can even be written
to further filter the output, if desired.
Identifying
the "Show" Line parameters
Now
that the "Pick" and "Show" line's formulas
have been written, we need to identify the information desired
to be seen for each security. Again, write a simple sentence
first and then replace it with the proper OpScan parameters.
Sentence:
I want to view the price of the stock, the respective IV's
for each expiration month and the average daily dollar volume
for the last 5 days.
Show
Line Parameters: LASTU, IV1, IV2, IV3, ATVOL$(5)
Simply
insert the appropriate OpScan parameter for each individual criterion
that is desired to be viewed and separate them with a comma and
a space. Let's view our work!
Hover over "Test Syntax" button
to check the validity of our OpScan formula
The
final steps in building an OpScan formula are to identify the
group of securities you wish to search in the "Include" section,
and to specify the maximum number of items you wish to have included
in your report.
That's
it! You have now built your first fully functional OpScan formula
that you can use to search for calendar spread candidates. View
the Opscan report.
You
can transfer the above information into OpScan and run the report.
Try changing the formula slightly and view the difference that
it may make to the output. Try creating new formulas on your
own and, if you need help, feel free to contact your product
consultant for assistance.
If
you are not a current subscriber, fill out the online
subscription form and start using OpScan to help you find
the options that meet your criteria...in a matter of seconds!
Log
into the OpScan forum on the message boards by clicking here: OpScan
Forum
|