100% found this document useful (1 vote)
270 views

Plug-In For Metastock - Version 7.2 and Higher: Operation Manual Trading Systems Analysis Group

Triangles explains the metastock addon software that searches for triangle setups , bullish or bearish. All formulas are included.

Uploaded by

Piet Nijsten
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
270 views

Plug-In For Metastock - Version 7.2 and Higher: Operation Manual Trading Systems Analysis Group

Triangles explains the metastock addon software that searches for triangle setups , bullish or bearish. All formulas are included.

Uploaded by

Piet Nijsten
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 45

Plug-in for MetaStock – version 7.

2 and higher
Version 2.00
Operation Manual

Trading Systems Analysis Group


Copyright © 2003

www.tsagroup.com
Trading Systems Analysis Group License Agreement
This is a legal agreement betweenyou, the end user, and the Trading Systems Analysis Group
Corporation.

BY PURCHASING THIS PACKAGE, YOU ARE AGREEING TO BE


BOUND BY THE TERMS OF THIS AGREEMENT. IF YOU DO NOT
AGREE TO THE TERMS OF THIS AGREEMENT, PROMPTLY
CONTACT THE TRADING SYSTEMS ANALYSIS GROUP TO MAKE
PRODUCT RETURN ARRANGEMENTS.
License

1. Grant. Trading Systems Analysis Group grants the right to use one copy of the described
product on any computer necessary for the explicit use of the purchaser.
2. Copyright. United States copyright laws and international treaty provisions protect the
manual, programmed code, and the layout of programmed code. Therefore, you must
treat this manual and included indicators, explorations, and DLL’s like any other
copyrighted material.
3. No other warranties. Trading Systems Analysis Group disclaims all other warranties,
expressed or implied, including but not limited to implied warranties of merchantability
and suitability for a particular purpose, with respect to the software and accompanying
written materials.
4. Limitation of Liability. In no event shall Trading Systems Analysis Group or its suppliers
be liable for any special, incidental, or consequential damages whatsoever arising out of
the use or inability to use this product.
5. Transfer. Transferring possession of any copy, modification, merged, or unmerged
portion of this product to another party automatically terminates the license. Violation of
the license by the purchaser or the end user will result in civil and criminal prosecution.

1
Legal Information
These indicators and functions do not represent a solicitation to buy or sell any securities nor are they a
claim that the methods and strategies are profitable. Past performance with any strategy or technique is not
indicative of future results.

The Trading Systems Analysis Group, the manufactures of this software and manual, are not affiliated with
any known market experts nor does the Trading Systems Analysis Group endorse the experts that teach
these strategies. There is no reciprocity with any known market or industry experts at the time that this
manual was written.

The Trading Systems Analysis Group is not responsible for, nor assumes any liability for, any damages
resulting from the use of this software package.

Equis, MetaStock, and The Explorer are registered trademarks of Equis International. All other product
names, indicator names, or strategy names are trademarks of the Trading Systems Analysis Group or are
registered trademarks of their respective owners.

2
Contact Information
Trading Systems Analysis Group
P.O. Box 521676
Salt Lake City, Utah 84152-1676

Technical support for this product is available through email to


[email protected]

Suggestions for product improvement should be emailed to


[email protected]

Visit us on the World Wide Web at:


www.tsagroup.com

MetaStock technical support is available from Equis International at:

Equis International
90 South 400 West
Suite 620
Salt Lake City, Utah 84101
Technical Support: (801) 265-9998
By email: [email protected]

3
General Information…………………………………………………………... 5
Introduction…………………………………………………………………… 6

Understanding The Triangles


What Is A Triangle………………………………………………………… 7
Pattern Method…………………………………………………………….. 12
Swing Method……………………………………………………………... 14

Exploring for Triangles


Running the Exploration…………………………………………………... 16
Reading the Exploration Report…………………………………………… 19
Exploring Triangles on Indicators…………………………………………. 21
Modifying the Exploration………………………………………………… 22

Viewing Triangles
Applying the Triangle Indicator…………………………………………… 24
Keeping the Triangle On the Chart………………………………………... 26
Deleting an Existing Triangle……………………………………………... 27
Changing Colors of Triangles……………………………………………... 28
Plotting Triangles on Indicators…………………………………………… 28

Appendix
Frequently Asked Questions………………………………………………. 30
Books that Reference Triangle Patterns…………………………………… 31
DLL Parameters…………………………………………………………… 32
Supplied MetaStock Formulas…………………………………………….. 34
Triangles with Trends (Reprinted)………………………………………… 36

4
General Information
This software was designed for people who are familiar with the common strategies used in trading triangle
breakouts. It gives you an easy way to scan for and select the stocks and commodities that will most likely
deliver the best results. It does not automate everything for you, nor does it give you buy or sell
recommendations. You will still need to decide for yourself if a stock or commodity is right for you, and if
any particular trade is worth doing.

We do not teach you ab out the markets in this manual, and strategy information in the manual is very
limited. You should be familiar with trading triangle breakouts by having attended a seminar or from boo k
o that you understand the strategies BEFORE using these formulas.

The one piece of trading advice we offer is that always having a stop in place is a good idea. If you do not
have exit orders in on each position you take, you should be able to see what’s happening throughout the
day. At the very least, look at the chart and other information at the end of each day.

5
Introduction
The Triangle II package is a very powerful tool for finding and trading triangle formations. Ther e are many
philosophies on how to identify and trade these types of formations and we have found a way to identify
many of them.

We assume you are already familiar with the triangle formation. If not, consider purchasing one of the
books at the end of this manual. There is a lot of power in the triangle formation, and a good und erstanding
of traditional techniques will help to make this package worthwhile to you.

Before going into the usage of the indicator and exploration, it is ideal to understand how this package
interprets triangles and what it uses to identify them. The two methods that are used in this package are the
Pattern method and the Swing method.

6
What is a Triangle?
Technical analysis involves seeing patterns in a security’s price movements on a chart. Each type of
pattern represents a category of trading activity. Generally, price patterns indicate a continuation of an
existing trend (continuation patterns), a reversal of the trend (reversal patterns), or consolidation
(consolidation patterns).

Consolidations offer excellent entry opportunities if and when a breakout comes. Triangles, which are a
consolidation type of pattern, are thus a popular and easily used technique for making a trading decision.
The principle is simple: Support and resistance lines are drawn to show the maximum extreme limit that
prices could go. If the price breaks through one of the lines, that tells you what direction the price will most
likely go.

A triangle is one of the most basic and recognizable technical analysis patterns. It is created by prices
coming to lower highs and higher lows at the same time. This is the “consolidation” of prices. A triangle
will typically look like this

As the triangle narrows to the intersection point (the "apex"), prices are expected to break out of one of the
two trendlines before the intersection occurs. Whichever direction the breakout occurs, prices are expected
to continue in that direction. This breakout movement is called an “expansion” when it occurs and is the
purpose of looking for triangles.

7
Triangles are categorized into three groups; Symmetrical, Ascending, and Descending. A symmetrical
triangle is the type previously described, with lower highs and higher lows. The range of triangles can also
be widened to include triangles that have higher lows and a flat line of highs, known as an a scending
triangle, and triangles that have lower highs and a fla t line of lows, known as a descend ing triangle. This is
an example of a descending triangle with an apex line drawn in the middle (an ascending triangle would be
the opposite):

The apex line is the midpoint between the upper and lower trendline, and gives you a clear indication as to
what direction the triangle is pointing. Many traders will also use an apex line for deciding where to place a
stop-loss once a trade has been entered.

Most people have two primary problems with technical patterns of any type. The first is the visual aspect.
Everybody sees the pattern they’re looking for with their own criteria and experience. This means that 10
people can look at a chart and see 10 different triangles. What accentuates this problem is that technically,
they all do qualify for triangle status.

This creates the second problem--too many triangles. At any point in time with a random sampling of
stocks, triangles can b e found on more than a third of them. With one out of every three stocks showing a
triangle of some kind, the technical triangle has become one of the easiest patterns to spot as well as the
hardest to trade profitably.

If 10 people can see 10 different triangles, and they are all technically correct, then how do you know
which one to trade? The answer for this applies to all technical patterns, not just triangles. The correct
pattern (triangle) to trade is the one that everyone else agrees is the correct one. Your being able to
see what the majority of technical traders see is the only criterion worth using, and in fact, it is the
framework for finding the best patterns of any type. If other traders don’t see the same triangle that you do,
then their money won’t be used to tr ade the breakout. If no money is going into or out of the security, then
the security will most likely just move sideways. Not every triangle results in a profit-making breakout. A
breakout occurs because a majority of market participants cause it to occur, which they can do only if they
see the triangle, too. Not understanding this concept is where most triangle traders fail.

8
On the good side, there are many tools, techniq ues, and methods for homing in o n the triangles that are
most likely to be recognized by other triangle traders. For example, traders more easily recognize faster
consolidations than slower consolidations. Triangles that occur in trends stand out from triangles that occur
in a sideways market. A breakout that occurs on an increase of volume has a greater chance on continuing
than a breakout that occurs on no increase of volume. Some traders will notice small triangles and not see
larger ones.

We find triangles. The Triangles II package automates the detection of triangles that have the best chance
of breakout success, and you can modify the criteria for judging the probability of breakout if you choose.

Here are some examples of successful triangle breakouts that Triangles II easily found when the program
was run as an Exploration.

9
10
11
Pattern Method
The Pattern method is better at finding triangles in intraday charts (5, 15, 30, and 60-minute charts) since it
is looking for a patte rn to develop and not requiring any minimum percentage movement.

The Pattern method finds the high point with lower highs on each side, and the low point with higher lows
on each side.

For example:

In the bar drawing here, this pattern point qualifies for pattern types 1, 2, 3, and 4. The center bar is
surrounded by four lower highs on each side. This creates a type-4 pattern point. Since a type-4 pattern
point requires the four lower highs on each side of a central bar, it would also produce 3 lower highs on
each side. A type-4 pattern point creates a type-3 pattern point by default, and also creates each lower
numbered pattern point.

Once a numbered pattern point has been identified, it looks for a second one of the same type. If a type-4
pattern point of the highs has been identified, it will then look for the next type-4 pattern point of highs
going back. The most recent type-4 pattern point high must b e lower than the high of the next type -4
pattern point of highs go ing backwards in the chart. This is because when the software is identifying the
resistance line of the triangle formation, it is looking for a progression of lower highs.

After all the topside patterns have been determined, the software then looks for a type-4 pattern point on the
low side. If a type-4 pattern point of the lows has been identified, it will then look for the next type-4
pattern point of low’s back. The most recent type-4 pattern point low must be greater then the low of the
next type-4 pattern point of lows going backward in the chart.

The exploration looks for all of these conditions. If all of the conditions are met (the most recent type-4
pattern point of highs being lower than the second one back, and the most recent type-4 pattern point of
lows being higher than the second one back) then the pattern becomes a triangle candidate.

12
In the image above, the four pattern points of a type-4 triangle have been identified. The top two center
points (labeled CP) have the highs lower than the center point numbered, creating two pattern points. The
same is shown for the low center points with the lows higher than the center point numbered. Notice that
the two low center points share a number 4 bar since the bar is lower than the two center points. Two center
points can share bars as long as the triangle criterion is still valid.

Once a candidate has been found, the upper and lower trendlines are calculated and a test is performed to
make sure prices do not fall outside of the upper and lower trendlines at any point in the pattern. If the
triangle passes this test, then the pattern is determined to be valid.

If there is no validation of a complete type-4 pattern, the software will start the process of looking for a
type-3 pattern, and so on until there are no patterns left to look for using the pattern method, or the lower
search limit is reached. It will then move on to the next security.

13
Swing Method

The Swing method is better at finding triangles in end-of-day charts (daily and weekly) since it is looking
for swings in the chart that can occur over longer periods of time and have larger movements.

The Swing method finds swings in the price that move by a minimum percentage. It uses the Zig-Zag
function to determine when a minimum percentage movement has occurred.

For Example:

Here is a Zig-Zag of the highs and a Zig-Zag of the lows. The Zig-Zag of the highs shows the most recent
peak being lower then the next one back. Conversely, the Zig-Zag of the lows shows the most recent trough
being higher than the next one back. This becomes the definition of a triangle candidate.

14
Once a candidate has been found, the upper and lower trendlines are calculated and a test is performed to
make sure prices do not fall outside of the upper and lower trendlines prematurely. If the triangle passes
this test, then the pattern is determined to be valid.

If an exploration is set to begin with a 10 percent swing, then the exploration looks for this situation to
occur with a minimum 10 percent move on the highs and the lo ws. If the conditions are met, then it returns
the percentage as valid. If the conditions do not occur, then it will try to match the conditions with a
minimum 9 percent move, and so on down to 1 percent or the lower search limit is reached.

15
Running the Exploration
For optimum performance, the Explorer should be set to load a minimum of 250 periods (1000 is
recommended), NOT load minimum records. Ideally, the Explorer should be set to load the same number
of periods that your charts are set to load.

To find out what your MetaStock Load Options are set to, click on File, and then Open. This will bring up
an open dialog box. Click on the Options b utton in the upper right-hand corner:

After clicking on this button, move down and click on Load Options. That will open a dialog box like this:

The value where Load is selected is the value to use in the explorer when working with triangles (in this
case, 1000 periods).

16
After you’ve made note of the value, close out of these boxes and go to the Explorer. Click on the options
button at the bottom of the dialog box:

This will open the Explorer Options dialog box. Take the value that you wrote down from the Open Chart
Load Options and place it in the Data Loading section with Load Records set (in the above example, 1000)
as shown:

Make sure that Load ‘number of’ Records is selected and not Load Minimum Records.

If Load Minimum Records is selected, MetaStock will reject all of the securities since it doesn’t know how
much data the triangles software requires to return a result.

17
When exploring stocks, you will probably not want to use the exploration on the entire stock market.
Triangles occur very frequently, even with filtering in place, and exploring the entire stock market could
result in a report of hundreds (if not thousands) of valid triangles cases at any time. It’s best to run the
exploration on securities that you would actually trade. For example, if you don’t trade penny stocks, then
don’t include them in your exploration. This will reduce the size of the exploration report to a more
manageable report, and reduce the time it takes to run the exploration.

You should also modify the exploration to search for triangles that you would actually trade. If you have no
intention of trading a triangle that is a size 3 Swing or less, then remove it from your exploration. It’s also
recommended that a maximum convergence length filter be set to prevent triangles that are too weak for
your trading style. Instructions for doing this can be found in the “Modifying the Exploration” section of
the manual.

18
Reading the Exploration Report
The triangles exploration is designed to be very powerful in what it is looking for.
Depending on how you set up the exploration, it can search a database of securities and report the
following:

1. Whether it found large, medium, or small sized triangle (or any combination thereof)
2. Which method (Pattern, Swing, or Both) detected the triangle
3. Whether the price is still within the triangle or whether it broke out today

Here is a sample report made by the exploration:

Security Name Swng Sml Swng Med Swng Lrg Pat Sml Pat Med Pat Lrg Ticker Symbol
MONY GRP 103 105 0 0 105 0 MNY
MOODYS COR 103 104 0 0 0 0 MCO
MSDW AS-PAC 0 0 108 0 0 0 APF
MULTEX.COM 2 0 0 1 0 0 MLTX
MULT GMS 0 0 108 0 0 0 MGAM
N C I BD SYS 103 106 110 0 0 0 NCS
N C O GRP INC 0 0 0 0 106 107 NCOG
N C R CORP 0 106 110 0 0 0 NCR
N L IND 0 0 108 0 0 0 NL
N P S PHARM 0 106 107 0 0 0 NPSP
N T L INC 0 0 110 0 0 107 NLI
NANOM INC 103 106 107 0 0 0 NANO
NARA BNC 0 106 110 0 0 0 NARA
NAT AUS BK 0 0 110 0 0 0 NAB
NAT COM BNC 103 106 0 3 0 0 NCBC
NAU ENT INC 0 106 0 0 0 0 NAUT
NAV INTL 0 0 110 0 0 0 NAV
NOVARTIS 0 106 0 0 0 0 NVS
NOV PHARM 0 0 0 103 105 0 NOVN
NVIDIA CORP 103 0 0 101 0 0 NVDA
NYSE Comp 0 106 110 0 0 0 NYA.X

For example purposes, National Commerce Bancorp (NCBC) will be used.

Security Name Swng Sml Swng Med Swng Lrg Pat Sml Pat Med Pat Lrg Ticker Symbol
NAT COM BNC 103 106 0 3 0 0 NCBC

First, the sizes and types of patterns are identified

1. Swng Sml Small size triangles using the Swing method (1, 2, and 3-percent swings)
2. Swng Med Medium size triangles using the Swing method (4, 5, and 6-percent swings)
3. Swng Lrg Large size triangles using the Swing method (7, 8, 9, and 10-percent swings)
4. Pat Sml Small size triangles using the Pattern method (Types 1, 2, and 3)
5. Pat Med Medium size triangles using the Pattern method (Types 4, 5, and 6)
6. Pat Lrg Large size triangles using the Pattern method (Types 7, 8, 9, and 10)

With NCBC, three columns were returned with values and three were returned with 0 (zero). If a column
returns zero, that means the condition was not met for that method and size. Here, there are three columns
with values: Swng Sml with 103, Swng Med with 106, and Pat Sml with 3.

19
If the exploration returns a value between 101 and 110, a triangle has formed, but has not broken out yet.
You are still in a position to set entries upon crossings of the upper or lower trendlines. In this case, the
Swng Sml column has a value of 103, and the Swng Med column has a value of 106. This means that two
triangle sizes have been identified using the Swing method, with a 3-percent swing and a 6-percent swing,
and that the price is between the upper descending and lower ascending trendlines.

If the exploration returns a value between 1 and 10, that means a triangle has broken out on the day the
exploration was run, as well as the size of the triangle that was broken out. In the case of the Pat Sml
column, the exploration returned a value of 3. Therefore, a breakout occurred on the day of exploration of a
Pattern method triangle with a size 3 pattern.

When there are two triangles of the same type but different sizes, it can mean that there are in fact two
different triangle sizes (as in the case above), or they can be the same triangle. Since the ‘triangle detect‘
function used in the exploration returns the largest triangle found in its size specifications, in the case above
it is possible that the criteria that matched a 3-percent swing detection also matched a 6-percent swing
detection. The 3-percent would still be shown since in the explorer, the Sml Swng column would detect the
largest triangle still functional at that size. Whether they are the same triangle or different triangles isn’t
known until the Triangle indicator is applied.

It is also possible that the Swing method and Pattern method will detect the same triangle. This can only be
determined by applying the Triangle indicator.

Once these values have been discovered, then the Triangle indicator can be applied to the chart. (See
Applying the Triangle Ind icator on page 24 )

20
Exploring Triangles on Indicators
One of the new powerful features of Triangles II is the ability to find triangle patterns in indicators, not just
price data. This is useful in volatility and momentum analysis, as well as for many other applications.

Performing an indicator triangle analysis requires either modifying an existing exploration, or creating a
new one. (A sample indicator exploration is provided.) See your MetaStock manual for instructions on how
to make explorations.

The formulas to use for indicator triangle detection are the same as for price triangle detection, except that
the last two parameters in the software call are different. In the sixth parameter in the software call, there is
an option to choose ‘price’ or ‘data’. Normally price is chosen, and if so, then the last parameter passed to
the software is ignored. But for exploring triangles on indicators, data needs to be selected as below.

ExtFml(‘‘tsatriangle.triangle_detect’’, Pattern, 20, 50, 0,


Pending, Data, RSI(14))

This tells the software that you will be passing in a data array and to evaluate triangles on that. In the above
example, a 14-period RSI has been chosen.

If the formula is put into a column, then it will return either the value of a pending triangle if one is found,
or a zero if no triangle is found. If modified slightly as below:

ExtFml(‘‘tsatriangle.triangle_detect’’, Swing, 20, 50, 0, Pending,


Data, RSI(14))>0

and placed in the filter of the exploration, then only securities that have a triangle (between 20 and 50%
swing) will be returned and all others will be left out of the results.

Depending on the type of indicator you are exploring, you may need to exaggerate the swing or pattern
sizes beyond what you would for prices. In the above example, the exploration starts at a swing size of 50%
and cycles down to 20% to find a triangle. In the case of the RSI, this may be appropriate since the RSI
moves between 0 and 100 and approaches both extremes fairly often. If a 3 to 5% swing range were
chosen, then a triangle may be too small to be worth anything (if found at all). Remember to adjust your
swing and pattern sizes appropriate to the indicator you’re exp loring and the technique you intend to use
with it.

Note: All other properties of the software call work the same for both price and data.

21
Modifying the Exploration

The basics of working with explorations and programming them can be found in the
MetaStock Users Manual that came w ith the MetaStock program. Th ese types of processes
can be utilized for anything that the user can program. Refer to the MetaStock Users
Manual for further information on custom formula programming.

Modifying your exploration is a key component to your triangle success. Without modific ation, an average
of more than 25% of all securities explored will return a triangle candidate. Typically, this is far too many
to be examined, and there is no qualifying information used to make sure it’s actually the triangle type that
you are looking for.

Most modifications fall into two categories:


1. Modifying the triangle software call, or
2. Modifying the triangle support criteria.

Modifying the DLL call requires some understanding as to what is being called and how. The appendix of
this manual contains the basic information for calling the DLL’s for the triangle package as well as for the
modifiable parameters for the DLL.

This section will focus on modifying the triangle support criteria.

When modifying an exploration, it is best to either make a new one from scratch, or to copy an existing
one. This way there will be a base point of reference of the original for future use.

If ever using the existing criteria of the supplied exploration, then the filter contents should always be
enclosed in parenthesis. This should be done before any other user-supplied modifications occur.

Change this:

ExtFml("tsatriangles.triangle_detect", Swing, 1, 10, 0, Both,


Price, 0)>0 OR
ExtFml("tsatriangles.triangle_detect", Pattern, 1, 10, 0, Both,
Price, 0)>0

to this:

(ExtFml("tsatriangles.triangle_detect", Swing, 1, 10, 0, Both,


Price, 0)>0 OR
ExtFml("tsatriangles.triangle_detect", Pattern, 1, 10, 0, Both,
Price, 0)>0)

(The parentheses in red should be added first)

After the parentheses are added, user additions can take place with minimal problems.

22
Detecting Increased Volume on Breakout
Volume increases on breakouts are a great way for validating a triangle. If there is a significant volume
increase on the bar of breakout, then there is a good chance that other traders are agreeing that it was a
valid triangle (or trendline) and are trading accordingly. If no increase in volume occurs, then most likely it
was a false breakout, or a false triangle all together (the market didn’t agree that a true triangle was present)

To add increased volume detection, here are two examples that can be used.

First, single day increase in volume:

The triangle filter should be modified so that it returns ‘Crossing’ triangles instead of ‘Both’. Next, with the
enclosing parentheses added, to the end of the filter add:

AND V>(Ref(V,-1)*1.5)

This compares takes the volume and requires that it be at least 50% greater than the previous day’s volume
for it to be considered a valid breakout. Another alternative to this is:

AND V>(Ref(Mov(V,5,S),-1)*1.5)

This makes the volume requirement be at least 50% greater than the 5-day average volume on the day of
the breakout.

Minimum/Maximum Price and Minimum Volume


This is a good filter to have to prevent triangles from showing up on securities that you otherwise may not
trade normally. A maximum and minimum price can be set up simply by adding greater then and less than
parameters like this:

AND C>5 AND C<140

This requires that any triangles returned have at least a price of $5.00 per share and has a maximum price of
$140.00 per share to be valid (assuming that stocks are being traded). (This type of function isn’t typically
useful in commodities/futures since the quoted values in one security are not cross compatible with the
values in another security.)

Adding a minimum volume requirement requires an understanding as to how your data provid er supplies
volume to MetaStock. Most data suppliers transmit volume/100 instead of true volume (for stocks). This
example will assume that Reuters is the data provider, and Reuters transmits volume/100 for stocks. So, to
reject all stocks that have volume less than 200,000 shares on average, a filter would be added like this:

AND Mov(V,20,S)>=2000

This takes a 20-period moving average of the volume and requires that the average be greater than 200,000
shares. (If the data provider uses true volume, then 200000 would be used instead of 2000). With the above
example, the volume would refer to a minimum of 2,000 contracts traded if explored on
commodities/futures. (Futures contracts are not transmitted as volume/100.)

If both a price and volume filter were to be added, then they would occur sequentially like this:

AND C>5 AND C<140 AND Mov(V,20,S)>=2000

23
Applying the Triangle Indicator
In this example, there are three options; a 6-percent Swing triangle, a 3-percent Swing triangle, and a size 3
Pattern triangle.

In the drop down Indicator Quicklist, apply the indicator called ‘TSA Triangle’ to the chart directly on top
of the price data.

A dialog box will come up asking for six options:


1. The type of triangle. This is whether to use a Swing method (1) or a Pattern method (2).
2. The size of the triangle. If Swing is chosen, then this is the size of the swing in percent. If Pattern
is chosen, the this is the number of bars that need to be contained on each side of a point for
measurement (how many bars on each side have to be lower than a central point for the upper line,
and how many bars on each side have to be higher than a central point for the upper line).
3. Whether to use price data or an indicator to calculate the triangle. This is set to price data by
default (1). For an indicator calculation to work the triangle needs to be plotted directly on the
indicator, and indicator (2) selected in this option.
4. The month to plot back. Defaulted to zero.
5. The day to plot back. Defaulted to zero.
6. The year to plot back. Defaulted to zero.

Options 4, 5, and 6 are only for placing a triangle on a chart that needs to be retained (discussed later in this
chapter).

24
For the examples given above, the indicator would be plotted three times to see all of the triangles returned
in the exploration. Plotting the first triangle listed (Swing 103) involves subtracting 100 from the value for
the triangle size (103 refers to a ‘pending’ 3-percent swing). In the dialog box, the type would be ‘1’ for
Swing, the size would be ‘3’, and the rest of the options would be left alone set on their defaults. Once set,
click on the ‘OK’ button

When the indicator is first applied to the chart, MetaStock will ask about scaling options. You should
merge with whatever scale your prices are being displayed on (usually the right side). If not merged on the
proper side, the lines will plot auto-scaled and will not align properly on the chart. Once the indicator is
plotted, you will see three lines:

1. An upper trendline
2. A lower trendline
3. A center line (the Apex line)

The upper trendline shows at what point the price must cross above to break out. The lower trendline shows
at what point the price must cross below to break out. The middle line (Apex line) is provided to show the
general direction of the triangle movement and is also provided for strategies that use an Apex line for stop-
loss purposes.

The apex shows which direction to expect a breakout to occur. If the apex is pointing upward, then you
should be looking for a breakout of the upper trendline. The opposite is true if the apex is pointing
downward. If trending sideways (or nearly sideways) then a breakout in either direction can be expected.

Depending on your trading style and philosophy, you may want to use the apex as a point to place a stop-
loss once the position is entered. This stop-loss needs to be changed daily until your price objective is met
or until you are stopped out of the position. (This should be a stop-loss that moves in the direction of the
trade.)

25
Keeping the Triangle On the Chart
New in Triangles II is the ability to place a static triangle on a chart that doesn’t disappear as new data
comes in. Once a triangle has been found that a trade decision is based on, the triangle should be re-applied
in a way that keeps in on the chart throughout the trade.

If intending to keep an existing triangle on the char t, double-click on one of the plotted lines in the triangle
indicator OR right-click on one of the plotted triangle lines and click on ‘TSA Triangle Properties’ This
will bring up the properties dialog box. Click on the parameters tab to bring the user entries to the front to
edit.

If there isn’t a triangle already plotted, then apply the ‘TSA Triangle’ indicator to the chart. This will bring
up the ‘TSA Triangles Properties’ dialog box. If the parameters tab isn’t already at the front, click on it to
bring up the user entries to edit.

Select the Type of triangle, the Size, and Price (of being plotted on price). Then enter in the month (1-12),
the day (1-31), and the year (1900-2100) that you want the triangle placed on. This date is the last date for
the triangle to plot, not the first date of the triangle lines. Once the triangle is placed, it will remain there as
long as you don’t delete the indicator and also as long as you save the chart (or smart chart). As long as
your chart is saved, MetaStock should retain the settings that your triangle indicator has.

MetaStock will allow you to have many triangles plotted on your chart, so a history of triangles traded can
be kept on the chart. How many triangles can be applied and retained is dependent on your systems
resources.

Note: There has to be a calculatable triangle on the date entered for a triangle to show. As with a triangle
applied to a chart normally, if no triangle is present with the specified parameters, nothing will show.

If a date is entered that is not on the chart, then the TSA Triangles indicator will try to plot a triangle on the
last date (bar) on the chart. If there is not a valid triangle with the specified parameters, then nothing will
plot.

26
Deleting an Existing Triangle
Deleting a visible triangle is as easy as clicking on one of the triangle lines and pressing the delete key on
your keyboard, or right clicking on an indicator line and clicking delete on the side-menu that comes up.

Sometimes a triangle is plotted improperly (wrong size, wrong type, wrong date, etc.), which causes the
indicator not to plot, even though the indicator is technically on the chart.

Deleting a triangle that was plotted improperly requires a different process than a visible triangle, and there
are a couple of ways to do it.

First, if the triangle was just applied and nothing else has been done to the chart, then you can click on Edit,
and then Undo. This will undo the last operation on the chart (in this case, applying an invalid triangle).
Holding down the Ctrl key and then pressing ‘z’ will do the same thing (Microsoft’s universal Undo hotkey
command).

The second way is to click on something on the chart (price data, volume, another indicator, etc.) so that
handles come up on the chart (little black boxes to show you the ‘selected’ item). Once the boxes are
displayed, press the Tab key on your keyboard. This will move the black boxes to another item on the
chart. If the tab key is continually pressed, then eventually the boxes will disappear. This means that an
item is now selected that can’t be seen (like an improperly applied triangle, for example). At this point,
press the delete key on your keyboard and delete the triangle. This should remove the triangle from the gray
title bar of the chart.

27
Changing Colors of Triangles
When several triangles are on the chart, it can be advantageous to color-code them, especially when they
are close together.

The easiest way to set a triangle’s color is right when it’s applied. With the TSA Triangle Parameters box
up (the one where you enter your triangle parameters), click on the Color/Style tab and select the color you
want the triangle to be. This is the best way since all colors are set simultaneously.

If a triangle is already applied, then each line in the triangles needs to be set individually. Either double-
click on a triangle line, or right-click on one of the three lines and select ‘TSA Triangle Properties’. This
will bring up the Properties dialog box. Click on the Color/Style tab select the color you want the line to be,
and then click on OK. This will have to be repeated again on the other two remaining lines for all three to
be changed.

Plotting Triangles on Indicators.


If a triangle exploration is run on an indicator instead of price data, then it becomes worthwhile to plot the
triangle on indicators that come up in the exploration report. Once the chart is open and the corresponding
indicator applied to the chart, then the triangle can be applied to the indicator. Unlike plotting a triangle on
price data, plotting a triangle on an indicator is not simply dropping the triangle indicator into the same
inner window as the indicator that the triangle should be applied to.

Once the primary indicator is applied to the chart (this would be something like Stochastics, the RSI, or
whatever indicator that was explored on) then the TSA Triangles needs to be dragged down to the same
inner window as the indicator and dropped right on top of the indicator itself. The indicator that the
triangle is being applied to will change color to purple. Only when the indicator is purple should the mouse
button be released. This will send the indicator to the TSA Triangles DLL. When the dialog box comes up,
the third option down the user entry screen will need to be changed from Price (1) to Indicator (2). Once
all of the other triangle parameters are set, click OK and the triangle will plot.

If the actual indicator is not selected (not having turned purple when the mouse button is released) then no
triangle will plot and it will need to be applied again with the indicator actually changed to purple.

28
Appendix

29
Frequently Asked Questions.
Why isn’t a trend considered when determining a tria ngle condition?

There are two main reasons for this:

1. Many trading philosophies don’t require a trend to be occurring or don’t agree on the direction of
the trend to take the trade.
2. Few people can agree as to what rules determine a trend and to how strong the trend should be.

To be able to accommodate the philosophies of many users, it wasn’t realistic to claim the parameters that
should be used. While many people believe that triangles are a continuation pattern, others view them as a
reversal pattern, and some don’t care about any trend at all.

The user is able to add their own trending parameters if desired.

Why doesn’t the indicator plot all o f the occurrences of the triangles on a chart (and why do they
ultimately disappear from the chart)?

The base indicator can only show the active triangle, and will only show it for as long as the specific
triangle is maintained. This means that as a new piece of a pattern or a new swing comes into form, the
indicator will disappear if the new information doesn’t also conform to the definition of the triangle.

Why does the exploration return breakouts as the specific sizes and tradable securities as the specific
sizes plus 100 instead of the other way around?

There are two reasons for this. The first reason is that adding 100 makes the results stand out more visually
as opposed to the specific size by itself. If using a setting of “Both”, this makes it easy to identify tradable
securities quickly by just glancing at the report.

The second reason is that the majority of people want to view the larger triangles first. If the exploration
report is sorted in descending order then the largest will be displayed at the top of the report. If the results
were returned the other way around, then ascending order would show the tradable securities first but the
smallest triangles would be at the top of the report.

30
Books that Reference Triangle Patterns
Some standard references on triangles include (but are not limited to) the following:

Technical Analysis of the Financial Markets


By John Murphy

Schwager of Futures – Technical Analysis


By Jack D. Schwager

Technical Analysis and Stock Market Profits


By Richard W. Schabacker

Curtis Arnold’s PPS Trading System


By Curtis M. Arnold

Trading the Odds


By Cynthia Kase

Encyclopedia of Chart Patterns


By Thomas Bulkowski

Trading Classic Chart Patterns


By Thomas Bulkowski

Technical Analysis of Stock Trends


By Robert Edwards and John Magee

These books and others in this field can by purchased from our bookstore at www.tsagroup.com

31
DLL Parameters
The DLL’s are not allowed to be redistribut ed to other users or packaged in any distribut ed product
for any reason. This is a violation of the license agreement. They are allowed to be used by the
purchaser of the Triangles package only.

The information for calling the two triangle DLL’s are provided here for those that wish to use them in
their own formulas. It is assumed that the user is familiar with programming MetaStock and calling
functions.

triangle DLL Call

This call is for generating the high and low lines to plot on a chart. Example Format:

ExtFml("tsatriangles.triangle", type, size, high/lowline, Price/Data, Data Array, Bars Back)

1. Type: This is for the triangle type, either 1 for Swing, or 2 for Pattern.
2. Size: This determines the size of the triangle. If Swing is selected, then this value represents the
swing percentage to use. If Pattern is selected, then this represents how many lower highs or
higher lows must occur from a central point for a high or low point to be calculated. Regardless as
to whether Swing or Pattern is selected, this value needs to be an integer. If swing is selected and a
10-percent triangle is desired, then 10 would be the value entered, not .1 or 10%. A valid size is
any whole number between 1 and 99.
3. High/Lowline: This is whether the DLL will return a data array for an upper trendline to plot, or
for a lower trendline to plot. Acceptable entries are H, Highline, L, or Lowline.
4. Price/Data: This is for declaring whether the calculation will be performed on either 1 for Price
information (highs and lows of the charts prices), or 2 for a user supplied data array (such as an
indicator).
5. Data Array: This is only used if Data is chosen from the Price/Data selection. This can be any data
array that MetaStock can handle, i.e., Stochastics, RSI, etc. For example, if a 14-period RSI of the
price needs to be passed, then this would have RSI(14) in this section. If Price is selected from
above, then any array entered here will be ignored. For clarification when writing your formulas, 0
(zero) should be used here if Price is selected above.
6. Bars Back: This is used to determine how many bars looking back from the last bar should be used
in the triangle calculation. If a triangle is to be calculated and applied for five days ago, then 5
would go in this section. The TSA Triangle indicator for plotting a triangle on a specific date uses
this part. Note that MetaStock handles the date to bars back conversion in the MetaStock code of
the indicator. Reference the indicator to see how this is done.

Example of Use:

ExtFml("tsatriangles.triangle", 2, 2, L, 2, RSI(14), 10)

If a valid triangle exists with these parameters, then this will evaluate a Pattern triangle, size 2, and return
the lower trendline. It will calculate on Data instead of Price, and it will use the 14-period RSI for the data
array. It will perform the calculation on the RSI as of 10 bars ago looking backwards from the end.

(Colors are added for clarity and are not part of the formula call.)

32
triangle_detect DLL Call

This call is for detecting triangles on a chart. It’s primary use is in the explorer. Example Format:

ExtFml("tsatriangles.triangle_detect", type, low search size, high search size, Max Convergence,
Crossing/Pending/Both, Price/Data, Data Array)

1. Type: This is for the triangle type to look for. The choices available are S, Swing, P, or Pattern.
2. Low Search Size: This is the smallest triangle to search for given the supplied criteria (Type, Max
Convergence, etc.). The triangles_detect DLL will search in order from the largest to the smallest
and return the largest triangle found. Regardless as to whether Swing or Pattern is selected, this
value needs to be an integer. If swing is selected and a 10-percent triangle is desired, then 10
would be the value entered, not .1 or 10%. A valid size is any whole number between 1 and 99.
This value needs to be equal to or less than the High Search Size.
3. High Search Size: This is the largest triangle to search for given the supplied criteria (Type, Max
Convergence, etc.). The triangles_detect DLL will search in order from the largest to the smallest
and return the largest triangle found. Regardless as to whether Swing or Pattern is selected, this
value needs to be an integer. If swing is selected and a 10-percent triangle is desired, then 10
would be the value entered, not .1 or 10%. A valid size is any whole number between 1 and 99.
This value needs to be equal to or greater than the High Search Size.
4. Max Convergence: This is a filter that eliminates triangles that don’t co nverge fast enough for
trading purposes. This value is the maximum number of bars that can exist before a triangle
convergence (the upper and lower trendlines intersect) is required. For example, if a value of 20 is
placed here, then the triangle will have to have an upper and lower trendline that will converge
sometime within the next 20 bars. If it takes more than 20 bars to converge, then the triangle will
be rejected and the next smaller triangle will be evaluated. Note that this is the maximum time to
convergence, NOT the maximum time to breakout. A breakout can (and usually will) occur long
before the convergence of a triangle occurs. The values allowed for an actual convergence are 1 to
65500. If all triangles are to be allowed (no maximum convergence), then set this value to 0 (zero ).
5. Crossing/Pending/Both: This entry determines what status a triangle needs to have to be returned.
A crossing triangle is a triangle that has a breakout (of either the upper or lower trendline) as of
the last bar of exploration. A pending triangle is a triangle that has formed but has not yet broken
out, and is therefore still tradable. Both returns crossing and pending triangles. Acceptable entries
are C, Crossing, P, Pending, B, or B oth. If a crossing triangle is returned, then 100 will be added
onto the value to distinguish between a pending and a crossing triangle.
6. Price/Data: This is for declaring whether the calculation will be performed on either 1 for Price
information (highs and lows of the charts prices), or 2 for a user supplied data array (such as an
indicator).
7. Data Array: This is only used if Data is chosen from the Price/Data selection. This can be any data
array that MetaStock can handle, i.e., Stochastics, RSI, etc. For example, if a 14-period RSI of the
price needs to be passed, then this would have RSI(14) in this section. If Price is selected from
above, then any array entered here will be ignored. For clarification when writing your formulas, 0
(zero) should be used here if Price is selected above.

There are no bars back in the triangle_detect function since an exploration can be edited to explore on a
specific day.

Example of Use:

ExtFml("tsatriangles.triangle_detect", Swing, 8, 20, 30, Pending, Price, 0)

Explore for Swing method triangles, retur ning the largest found between 8 and 20, that the upper and
lower trendlines will intersect within 30 periods. Return only Pending (not yet broken out) triangles and
evaluate on the securities Price data. (The last value is left at zero since price is being evaluated and not a
user supplied data array.)

33
Supplied MetaStock Formulas
TSA Triangle (Indicator)

type:=Input("Type: 1=Swing, 2=Pattern", 1, 2, 1);


size:=Input("Triangle Size", 1, 99, 5);
pp:=Input("1=Price, 2=Indicator", 1, 2, 1);
m1:=Input("Enter Month", 0, 12, 0);
d1:=Input("Enter Day", 0, 31, 0);
y1:=Input("Enter Year", 0, 2100, 0);

m2:=If(LastValue(IsDefined(BarsSince(Month()=m1 AND DayOfMonth()=d1


AND Year()=y1))),m1,LastValue(Month()));
d2:=If(LastValue(IsDefined(BarsSince(Month()=m1 AND DayOfMonth()=d1
AND Year()=y1))),d1,LastValue(DayOfMonth()));
y2:=If(LastValue(IsDefined(BarsSince(Month()=m1 AND DayOfMonth()=d1
AND Year()=y1))),y1,LastValue(Year()));

date:=LastValue(BarsSince(Month()=m2 AND DayOfMonth()=d2 AND


Year()=y2));

a:=ExtFml("tsatriangles.triangle",type,size,H,PP,P,date);
b:=ExtFml("tsatriangles.triangle",type,size,L,PP,P,date);
a;b;(a+b)/2

34
TSA Triangle (Exploration)

Column A: Swng Sml


ExtFml("tsatriangles.triangle_detect", Swing, 1, 3, 0, Both,
Price, 0)

Column B: Swng Med


ExtFml("tsatriangles.triangle_detect", Swing, 4, 6, 0, Both,
Price, 0)

Column C: Swng Lrg


ExtFml("tsatriangles.triangle_detect", Swing, 7, 10, 0, Both,
Price, 0)

Column D: Pat Sml


ExtFml("tsatriangles.triangle_detect", Pattern, 1, 3, 0, Both,
Price, 0)

Column E: Pat Med


ExtFml("tsatriangles.triangle_detect", Pattern, 4, 6, 0, Both,
Price, 0)

Column F: Pat Lrg


ExtFml("tsatriangles.triangle_detect", Pattern, 7, 10, 0, Both,
Price, 0)

Filter:
ExtFml("tsatriangles.triangle_detect", Swing, 1, 10, 0, Both,
Price, 0)>0 OR
ExtFml("tsatriangles.triangle_detect", Pattern, 1, 10, 0, Both,
Price, 0)>0

35
Triangles with Trends (Reprinted and Modified from the TSAGroup
Website)

Note that since this was originally written with the original triangle package, the
images are using the old package and may have titles within the charts that reflect
that. The information is still valid and functional with Triangles II.
One of the largest problems with triangles is that most experts don't agree on the rules that define valid
triangle patterns. Some experts require a certain type of triangle in an uptrend, while others say that the
same type of triangle should only be used in a downtrend. Some say to take either side of a triangle
breakout, while others say to only take a certain direction based upon some class of rules. The fact of the
matter is that there are many ways to trade triangles successfully, as well as many ways to loose money
with them.

What is going to be shown is not a guaranteed success to your trading. After all, this is trading and there are
no guarantees at all. But you will see a method to make your triangle trades have a higher percentage of
success.

The basic method of trading a triangle pattern is to wait for one to develop, and then take a long position if
it breaks above the triangle's resistance or a short position if it breaks below the triangle's support. The
general premise is that since a triangle is a consolidation pattern, then whichever way prices break out of
the triangle should be the direction that they should continue, and you as a trader would then hop on board
this breakout to acquire the profits.

The losses occur when the breakout from the triangle doesn't result in an up or down trend but instead
continues to move sideways, whipsawing you in and out of the trade while you're trying to jump on the
trend.

This technique is designed to reduce (not eliminate) the chances of that happening. It can be associated
with the classical physics concept of "a body in motion tends to stay in motion, and a body at rest tends to
stay at rest." (While classical physics has no true relevance here, it does get the point across as to the nature
of the technique.) If you are watching a market that is trading sideways, there is a higher probability that
any triangle pattern that develops is not a true consolidation pattern, but is just a common movement in an
ordinary market. Therefore you don't have a real breakout, instead you just have steady sideways
movement (more designed for ordinary support and resistance techniques, as opposed to a consolidation
type).

The basis of this technique is to trade triangles that are in a trending state. This way, prices are actually
consolidating from something. If prices are trending in a particular direction (showing control by the
bulls/bears) and a triangle occurs, then we see that at the point of consolidation there is a struggle going on.
If looking at a triangle in an uptrend and prices break to the upside then the triangle was a continuation
pattern. If it breaks to the downside, then the triangle becomes a reversal pattern. Either way, it will
typically show a "winner" at the point of the breakout. In a non-trending sideways channel, a triangle
normally occurs due to common fluctuations as opposed to a struggle for control.

While the chances of a price breakout from this type of pattern turning into a sideways market is still highly
possible, we have removed a very significant percentage of the failing patterns that would typically occur
from taking all available triangles. "Qualifying" the triangle with a known parameter (a trend) increases the
odds of success.

There are several ways to identify a trend condition. It can be observed visually (which is the primary way
it has been done thro ugh time), or using the Triangles software we can use indicators to determine if a trend
exists. The indicator approach will be used for the examples here.

36
Many people choose to make their own trending indicator, and there are no problems with that. Since what
defines a trend is fairly subjective, you should always use the indicator that fits best into your trading
philosophy and style. But there are also several fairly good trend-identifying indicators that are already
built-in to most software programs. Indicators like Wilder's ADX, r-Squared, or the Vertical-Horizontal
Filter (VHF) are all valid indicators that can be used.

When using a trend-identifying indicator, the trend length will want to be matched up with an appropriate
triangle size. For example, r-Squared and the Vertical-Horizontal Filter are both fairly fast indicators and
therefore you would want to use them with fairly small triangle patterns. If you use an r-Squared indicator
with a large triangle, then you run into the probability that the r-squared is identifying a short-term trend
within the triangle instead of the trend that is causing the triangle to occur. A 21-period r-Squared will
typically work well with triangles that are 8-bars or less (in total triangle size, not pattern or swing size).
More than that will cause it to either not show a trend when the triangle occurs, or to show the trend within
the triangle (which defeats the purpose of identifying the trend in the first place).

For the examples here, the 14-period Average Directional Movement Index (ADX) will be used. This was
chosen because it has a slower response than either the r-Squared or the Vertical-Horizontal Filter, and can
therefore allow the use of larger triangles.

A value of 30 was chosen to be the threshold for determining whether a trend existed or not. If a value of
45 - 60 were chosen it would be a greater qualifier, but would also result in a less likely chance of
detection. Since a triangle involves both up and down movement to be created, by nature it will reduce the
value of a trend-finding indicator when the triangle occurs. Good triangles may force the indicator below
the threshold values before it can be taken advantage of.

From a truly technical point (as opposed to a software one), the application of this
method is as simple as visually spotting a triangle pattern, and then applying the ADX
indicator to the chart to see what its reading is. If the ADX is above 30, then the triangle
is qualified.

37
Here is an example of how all of this works:

Here are actually several good triangle patterns. While the ADX was at its highest point at the beginning of
January, there was a very small triangle (about 5 bar s long at the beginning of January, or longer if you
show the resistance back to late December) that resulted in a successful breakout just before the middle of
January. Then towards the end of January another small triangle pattern developed, with the ADX still
being above 30, as well as another successful trade to the upside that could have been taken. In mid
February, another triangle setup occurs that looks almost exactly like the January triangle, except the ADX
is below 30, so the trade would never have been made. At the end of the chart there is a very definite
triangle. The ADX is above 30 and is starting to pull back (since the triangle pattern has significant down
moves within it.) The trend is up (according to the +DI and -DI indicators) and so either a trend
continuation or trend reversal would be expected.

38
The prices broke out to the short side with a potential gain of almost 20% in less than 2-weeks had a short
position been taken. Also notice that at the end of the short downtrend that another small triangle develops,
ultimately turning into a sideways market. The ADX is far below 30 at that point so this next triangle
would have never been taken.

Example 2:

Here, a triangle develops during a definite downtrend. The ADX is still around 40 even after an expected
pullback. The breakout could be taken on either side.

39
What happened is something that occurs frequently with triangles. In this case, the triangle broke out to
both sides during the next two consecutive days. It then huddled around those prices for several days before
taking off to the upside in mid March. Often a triangle will have a false breakout only to reverse harshly in
the opposite direction (as seen here). A trader with a good understanding of this type of phenomenon
realizes that when they occur, it is best to be onboard for the sudden move. The small loss that occurred due
to the false breakout would have been minimal to the potential profits by closing the position and taking the
long side (almost another 20% in 3 weeks).

40
Example 3:

Here, a triangle develops with definite breakout levels established, as well as a strong ADX reading to the
downside.

A breakout occurs on the eighth trading day into M arch, pulls back slightly, and then jumps to a short -term
high in less than two weeks. Assuming a trader was willing to wait, a large profit could have been acquired

41
Example 4:

A much longer and larger triangle, though still within a defined uptrend as shown by the ADX re ading
above 30.

42
This is another common occurrence with triangle patterns that should be watched for. A breakout to the
downside occurs with a complete pullback to the apex (middle line), and then forcefully moves in the
original direction of the breakout. This is another example of how getting stoppe d out and reentering the
position can result in a substantial return, more than offsetting the potential losses that can occur from
getting stopped out initially.

Note that it is also possible that at the retracement to the apex line, that the triangle could have been
redrawn to extend to the middle of March. This would also be a valid triangle pattern, but would have
failed the qualifying criteria since at that point the ADX was far below 30. (At the TSAGroup, we believe
that it is better to be excluded from potential gain than to be exposed to substantial losses, so not taking the
trade based upon that perspective would be consistent with our philosophy. You should determine ahead of
time what perspective you will take on such a scenario.)

43
Final Notes:

Qualifying a pattern is nothing new, and the concept cer tainly shouldn't be excluded from visual patterns
such as triangles. The ADX was used for its availability in most software, but remember that there are
hundreds of trend-defining indicators that already do exist or can easily be created. You may want to use
the ADX with more periods and at different thresholds for a stronger trend, or a completely new indicator
based upon your own ideas. Visually defining a trend also works well, as trends can sometimes be seen
even though the indicator s don't show it. Find a method tha t works for you.

Modifying the TSA Triangles Exploration for Trends

For the examples here, a 14-period ADX will be used to identify the trend. The original TSA Triangle filter
is set to:

ExtFml("tsatriangles.triangle_detect", Swing, 1, 10, 0, Both,


Price, 0)>0 OR
ExtFml("tsatriangles.triangle_detect", Pattern, 1, 10, 0, Both,
Price, 0)>0

Adding on to the formula requires enclosing the original portion in p arenthesis and then putting a space at
the end and adding an:

AND ADX(14)>30

The final Exploration filter would look like this

(ExtFml("tsatriangles.triangle_detect", Swing, 1, 10, 0, Both,


Price, 0)>0 OR
ExtFml("tsatriangles.triangle_detect", Pattern, 1, 10, 0, Both,
Price, 0)>0)
AND ADX(14)>30

This is the same way that you can add your own mechanical criteria to your explorations, which will also
narrow the available signals that are returned each night.

44

You might also like