MT5 indicators← Alligator Swing ZigZag product page日本語の取扱説明書

This product is in preparation for release. Product files are not yet distributed; the manual is published so that you can review its content. This manual is an English translation of the Japanese manual. Images (screens and figures) are not translated and may contain Japanese text or earlier names.

For Trilogy users

Alligator Swing ZigZag

It checks whether the whole candle is above or below the 3 average lines. When a bar goes to the side opposite the last outside bar, it confirms the top or bottom of the segment and places a mark at the extreme price on that bar.

Indicator name: Alligator Swing ZigZagMetaTrader 5Price chart

Outside above → bars touching the lines → outside below confirms the top

Last outside-above barNeutral barsConfirmed outside belowHigh of the search segmentTop mark
Schematic diagram of how to read it. This is not an actual terminal screen.
1

Look at the 3 lines and the whole barJaw is blue, Teeth magenta and Lips gold. If the low is above all 3 lines, the bar is outside above; if the high is below all of them, outside below.

2

Confirmed when the outside side changesFrom outside above to outside below gives a red top; the reverse gives a green bottom. A bar touching the lines is not treated as outside, and the side of the last outside bar is kept.

3

Separate height and timeThe height of the mark is the extreme price of the segment, and the horizontal position is the confirming bar that went outside on the opposite side. The blue zigzag connects those confirmed points.

Jaw 13/8, Teeth 8/5, Lips 5/3SMMA, median priceBy default, marks on closed barsMT5, no account authentication
1

MT5 display and examples of changed settings

Compares the default settings and a settings change example on a screen with only this product applied.

Settings change example: these items are changed
Calculation method shared by the 3 lines / MA Method
InpMethod
SMMA → LWMA
Price used, shared by the 3 lines / Applied Price
InpPrice
Median → Typical

All other inputs remain at their defaults. On a PC, the default is on the left and the change example on the right; at smartphone width they appear in the same order from top to bottom.

Default settingsInpMethod = SMMA / InpPrice = Median
Alligator Swing ZigZag default settings
Defaults: Jaw 13/8, Teeth 8/5, Lips 5/3 (period/Shift), SMMA, Median, Closed Bars Only true. Displays 3 average lines, a blue zigzag and red and green confirmation marks.
View the screen in detail at full size
Alligator Swing ZigZag default settings (full size)
Settings change exampleInpMethod = LWMA / InpPrice = Typical
Alligator Swing ZigZag settings change example
Change example: MA Method changed to LWMA and Applied Price to Typical. The periods, Shift and Closed Bars Only stay at the defaults. This example changes 2 items at the same time and cannot be read as the effect of only one of them.
View the screen in detail at full size
Alligator Swing ZigZag settings change example (full size)

Example shown: M1. This is an example for explaining the display. The published images are screens from before the brand display was added. The calculation and drawing conditions are the same, and the packaged version has display settings for the brand text and the QR code. The settings change example is not a recommended value. Details can be checked in the full-size view. Please also check the price scale of the main chart and the positions of the candlesticks.

2

How to read it in 30 seconds

Do not judge by the close alone

The condition is that the whole bar, including wicks, is outside the 3 lines. A bar touching the same price as a line is not outside either.

Find the last outside bar

If outside bars on the same side continue, the starting point of the search also moves to the newer bar. Neutral bars in between do not update the starting point.

Read the confirmation mark

The extreme is confirmed on the bar that went outside on the opposite side. No mark is placed yet on the first outside bar.

3

What it measures

It organizes the extremes of segments from changes in the position of bars relative to the band of moving averages. It is not an indicator that looks only at the order or crosses of the 3 lines, nor one that predicts future tops and bottoms.

3 average lines

Specify a period and Shift for Jaw, Teeth and Lips. The method and price used are shared by the 3 lines. The line at bar t is the average value at t−Shift, and future prices are not used.

Outside above / outside below

If the Low is strictly higher than the maximum of the 3 lines, the bar is outside above; if the High is strictly lower than the minimum, outside below. The position of the close alone does not decide it.

Neutral bars

A bar that touches a line, crosses a line, or lies between the lines is neutral. The side and bar of the last outside bar are kept, and no point is drawn.

Range for confirming a top

When the last outside bar was above and an outside-below bar then appears, the highest high from the last outside-above bar to the current bar is confirmed. Both end bars are included, and the highs of neutral bars are included too.

Range for confirming a bottom

When the last outside bar was below and an outside-above bar then appears, the lowest low of the same range is confirmed. Because the starting point is updated each time outside bars on the same side continue, it is not the whole segment from the previous confirmed point.

Confirmed points and line segments

The extreme price is placed on the current confirming bar. On the first outside bar it is only recorded, and a point is created only when a bar goes outside on the opposite side. A blue line segment needs 2 confirmed points.

4

Situations for reading the display

A red peak appeared

Indicator
From a state where the last bar was outside above, a bar went outside below.
Cross-check
Look at the last outside-above bar and the highest high from there to now.
Check
Read it as a past high recorded on the current confirming bar.
Caution
It does not mean that the price could be sold on that bar, or that a fall will follow.

A green trough appeared

Indicator
From a state where the last bar was outside below, a bar went outside above.
Cross-check
Look at the last outside-below bar and the lowest low of the segment.
Check
Separate the height from the time of confirmation.
Caution
It is not a buy instruction or a guarantee of a rise.

It looks as if price broke through the lines, but there is no mark

Indicator
Even if only the close is outside, the bar is not outside if a wick touches a line.
Cross-check
Compare Low/High with all 3 lines.
Check
Also distinguish a continuation on the same side, the first outside bar, and the forming bar.
Caution
It is not a product that draws a point at every cross or touch of the lines.

Neutral bars continue for a long time

Indicator
The side of the last outside bar is being kept.
Cross-check
Check whether the next outside bar is on the same side or the opposite side.
Check
The highs and lows of the neutral period may also be included in the next extreme search.
Caution
Neutral itself is not a buy or sell, nor a judgment that the whole market is in a range.

Changing the method changed the points

Indicator
When the average lines change, which bars are outside and the starting point of the search also change.
Cross-check
Compare 1 item at a time on the same history.
Check
The change example changes LWMA and Typical at the same time.
Caution
A setting with more points is not better, and these are not recommended values.
5

Steps for checking the display

1

Apply with the defaults

Check Jaw 13/8, Teeth 8/5, Lips 5/3, SMMA and Median, Closed Bars Only true.

2

Wait until the lines are available

By default, all 3 lines are available from bar 21, counting the oldest as bar 1. After that, a first outside bar and an outside bar on the opposite side are needed.

3

Compare the whole bar with the lines

Look not only at the close or the body but also at the wicks. An equal-value touch is not outside.

4

Check the time and height of the mark

By default, the point is confirmed after the confirming bar closes. It is not a point moved to the bar of the past extreme.

6

Installation and checking the package contents

Included filePurpose / location
TRI_Alligator_Swing_ZigZag.ex5The MT5 main file. Place it in MQL5/Indicators.

The ZIP contains only 1 item, the main file. The manual is opened from the product page on the site. Source code is not included. MT5 only; registration, account authentication and placing a license file are not required. Use it without changing the file name.

1

Extract the ZIP

Extract the ex5 main file rather than leaving it in the compressed file.

2

Open the data folder

In MT5, open MQL5/Indicators from 'File → Open Data Folder' and place the included ex5 there.

3

Apply this product

Refresh the Navigator or restart MT5, and apply it to the target chart. When comparing different settings, using separate charts makes checking easier.

4

Check the settings and display

First check with the default values. Changes and removal are done from the chart's 'Indicators List'.

Using this product does not require allowing DLLs. When removed, this product's drawings are cleared.

7

Settings

There are 13 inputs. Change them on the Inputs tab of the properties. The English item names defined in the source are shown together with the input names.

Jaw period

English item name
Jaw Period (1 to 500)
Input name
InpJawPeriod
Default
13
Allowed range
Integer 1 to 500
Description
Default 13. The calculation period of the blue average line.

Jaw shift bars

English item name
Jaw Shift (0 to 100)
Input name
InpJawShift
Default
8
Allowed range
Integer 0 to 100
Description
Default 8. The average from 8 bars earlier is drawn at bar t. It is not a forecast of the future.

Teeth period

English item name
Teeth Period (1 to 500)
Input name
InpTeethPeriod
Default
8
Allowed range
Integer 1 to 500
Description
Default 8. The period of the magenta average line.

Teeth shift bars

English item name
Teeth Shift (0 to 100)
Input name
InpTeethShift
Default
5
Allowed range
Integer 0 to 100
Description
Default 5. The average from 5 bars earlier is drawn at bar t.

Lips period

English item name
Lips Period (1 to 500)
Input name
InpLipsPeriod
Default
5
Allowed range
Integer 1 to 500
Description
Default 5. The period of the gold average line.

Lips shift bars

English item name
Lips Shift (0 to 100)
Input name
InpLipsShift
Default
3
Allowed range
Integer 0 to 100
Description
Default 3. The average from 3 bars earlier is drawn at bar t. With 0, it is the average of the current bar.

Calculation method shared by the 3 lines

English item name
MA Method
Input name
InpMethod
Default
SMMA
Allowed range
SMA / EMA / SMMA / LWMA
Description
Default SMMA. 4 types: simple, exponential, smoothed and linear weighted.

Price used, shared by the 3 lines

English item name
Applied Price
Input name
InpPrice
Default
Median
Allowed range
Close / Open / High / Low / Median / Typical / Weighted
Description
Default Median=(High+Low)/2. The outside check and the extreme search use High/Low regardless of the setting.

Check points on closed bars

English item name
Closed Bars Only
Input name
InpClosedBarsOnly
Default
true
Allowed range
true / false
Description
Default true. The outside check is not done on the latest bar, but the lines are drawn. With false, points also appear on the latest bar and appear and disappear until the bar closes.

Brand display and QR

English item name
Show Trilogy brand and QR code
Input name
InpTriBrandShow
Default
true
Allowed range
true / false
Description
Switches the brand text and QR display on or off.

Brand display position

English item name
Brand position (chart corner)
Input name
InpTriBrandCorner
Default
Bottom left
Allowed range
Top left / Bottom left / Top right / Bottom right
Description
Choose from the four corners of the chart.

Brand horizontal offset

English item name
Brand horizontal offset (pixels)
Input name
InpTriBrandX
Default
10
Allowed range
Integer. Limited to 0 to 2000
Description
Adjusts the horizontal margin from the specified corner, in pixels.

Brand vertical offset

English item name
Brand vertical offset (pixels)
Input name
InpTriBrandY
Default
10
Allowed range
Integer. Limited to 0 to 2000
Description
Adjusts the vertical margin from the specified corner, in pixels.
8

Usage specifications

Confirmed dots

When bars are added with the same history and settings, dots on closed bars are not moved to past extreme bars. Settings changes, adding older history or corrections may change recalculated results.

Handling of the latest bar

Even with true, the lines are drawn up to the latest bar. If Shift is positive, past averages are referenced; if 0, the average of the forming bar updates. Dots with false are displays before confirmation.

Right end of the lines

The average lines stop at the latest bar. They are not extended into the future side of the chart by the Shift amount.

Blue segments

A point is connected to the previous one only after the next confirmation point forms. The diagonal line of the completed picture as a whole was not visible from intermediate times.

Functions not included

There is no upper limit that cuts off at 50 dots, no constant extension to forming extreme candidates, and no notifications, orders, account authentication or license file.

For on-screen display only

The display is a record of calculation results. It does not direct trading decisions and does not guarantee future price movements.

9

Troubleshooting and usage notes

No mark even though it is the first outside bar

At first, only the outside side and the bar are recorded. There is no point until a bar goes outside on the opposite side.

A top lower than the previous top appeared

The search starts not from the previous confirmed point but from the last outside bar on the opposite side. If outside bars on the same side continue, the starting point is also updated.

The lines overlap and there are no points

The relative sizes of the 3 periods and Shifts are not enforced. With period 1 and Shift 0, if the selected price is within the current bar's range, the whole bar cannot go outside that line, and some settings give no points.

The gold line is hard to see

On a light background, gold can be hard to see. Check with the chart background, the scale, and the full-size images.

Inputs are not accepted

Choose periods as integers from 1 to 500, Shifts as integers from 0 to 100, the method from 4 types, and the price from 7 types.

The mark is away from the bar

The mark price is the high or low of a segment that includes the past. It is not necessarily within the high-low range of the confirming bar.

If the first display does not appear, check history loading and the input ranges. If an earlier display has stopped updating, first check the price feed and the terminal's connection status.

10

Technical information and specification details

Start position of the lines

Counting the oldest as 0, SMA/SMMA/LWMA have values from Period−1+Shift of each line, and EMA from Shift. The outside check is made from the bar where all 3 lines have values. The maximum default start position is 20 (the 21st bar).

Initial value of the average

EMA starts from the oldest price, and SMMA from the simple average of the first period. A match with MT4's initial values is not guaranteed.

Strict outside conditions

Above is Low>max(Jaw,Teeth,Lips), below is High<min(Jaw,Teeth,Lips). Equal values are neutral. The order of the 3 lines and the Force Index are not conditions.

State update

For an outside bar, the last bar is updated even on the same side. For a neutral bar, the state is kept. When a bar is outside on the opposite side, the extreme is found from the previous outside bar to the current bar, including both ends. Which bar had the extreme is not used as the next starting point.

Price definitions

Median=(High+Low)/2, Typical=(High+Low+Close)/3, Weighted=(High+Low+2×Close)/4. Shift is a number of bars, not points or pips.

Published images and scope verified

M1 is the timeframe shown when the display example was created, and the price series is mainly at 30-minute intervals. It is not the frequency of appearance on actual 1-minute bars. The published images are screens before the brand display was added; the screen display on the product with the brand display has not been checked yet.