Table of Contents
About EA
About Gotobi Days and Nakane
Non-trading Days
Brokers
Currency Pairs
Time Frames
Additional Orders
Account History Display Period
Parameter Explanation
FAQ
Update History
About EA
This EA trades by taking into account the time when the nakane for Gotobi days is determined.
On Gotobi days, trading starts at the specified start time and closes at the end time.
Additionally, it also supports "advance Gotobi days" where the next Gotobi day falls on a bank holiday. In such cases, the preceding business day becomes the Gotobi day.
Some holidays, such as the vernal equinox and autumnal equinox, change dates yearly, but this EA can handle them as well.
About Gotobi Days and Nakane
Gotobi days refer to days that include 5 or 10, meaning "5th, 10th, 15th, 20th, 25th, and 30th."
However, if the month's last day is not the 30th, the month's end day replaces the 30th.
In Japanese business practices, Gotobi days are considered to have higher funding needs.
There might be varying opinions on the month's end day, but many articles consider it a Gotobi day with increased funding needs, hence its inclusion.
Nakane is the forex rate determined by banks at 9:55 AM on each business day.
This rate becomes the settlement rate for the bank's transactions for that day, and a higher rate (USD/JPY) is beneficial for banks.
Therefore, it is said that from around 9:55 AM on Gotobi days (5th, 10th, 15th, 20th, 25th, 30th), USD tends to appreciate, and JPY tends to depreciate.
Conversely, after 9:55 AM on the same day, USD tends to depreciate, and JPY tends to appreciate due to the reaction.
Non-trading Days
The following days will not involve trading, even if they are Gotobi days.
Bank Holidays
Bank holidays refer to:
・Saturdays
・Sundays
・Public holidays
・Year-end and New Year holidays (December 31 - January 3)
On these days, Nakane is not determined.
Following the policy for Gotobi day trading, no trades are conducted on Gotobi days that fall on bank holidays; instead, the preceding business day is treated as an advance Gotobi day.
While Saturdays, Sundays, and public holidays are commonly recognized as holidays, December 31 - January 3 are legally designated bank holidays by law.
Christmas (December 25)
December 25 is a Gotobi day, and the Japanese forex market is open if it is a weekday, but MT4 charts stop.
(Presumably because foreign markets are closed)
However, the chart stops at 7 AM Japan time, and it operates at midnight.
Therefore, if the "trade start time" is set before 7 AM, trading will begin.
However, Nakane determination time, often set as the "trade end time" at 9:55 AM, is when the chart stops.
Unable to settle at that time, positions may continue to the next business day.
To avoid such situations, trading is specially suspended if the 25th is a weekday.
If the 25th is a holiday, normal Gotobi day rules apply, and the preceding business day will be an advance Gotobi day.
Brokers
Supports brokers in any timezone.
By default, it adapts to brokers using US daylight saving time, GMT+3 in summer and GMT+2 in winter.
Other brokers need to adjust the time difference parameters accordingly.
Currency Pairs
USD/JPY (US Dollar/Yen) is recommended.
Time Frames
Any timeframe is acceptable as the EA does not depend on chart formations.
Additional Orders
Due to requests for averaging down when incurring unrealized losses, an additional order function has been implemented.
If "Number of Additional Orders," "Interval Between Additional Orders," and "Lot Multiplier for Additional Orders" parameters are all set, additional limit or stop orders will be placed at the trade start.
Settlement will occur simultaneously when normal orders are settled.
(This is also true if the "Take Profit Amount" or "Stop Loss Amount" conditions are met)
Note that by default, additional orders will not be placed as the initial values do not meet the criteria.
Please configure settings as necessary.
Account History Display Period
While not mandatory, we recommend setting the display period of the "Account History" tab in MT4 to something
other than"All History."
This is because it can affect EA behavior.
When determining whether trading can start, the trade history is searched to check if trades have been made on that day.
This search targets the content displayed in the "Account History" tab.
If the display period is set to "All History," all records will be searched.
The more history entries, the longer the processing time.
It should not be an issue unless there are extreme amounts of history, but please verify settings if performance slows.
Parameter Explanation
Order Type
Set whether to perform buy or sell trades.
Run two instances of this EA, with one having a trade end time of 9:55 AM for "buy" and the other with a trade start time of 9:55 AM for "sell." This setup allows trades considering the USD appreciation/JPY depreciation trend towards 9:55 AM and the USD depreciation/JPY appreciation trend after 9:55 AM.
Lot Size
The lot size set during trading.
If 0, the lot size is variable.
Reference Amount for Variable Lot Calculation
The type of amount referenced when calculating the lot size for variable lots.
Selectable from "Account Balance," "Equity," or "Free Margin."
Amount per Lot
The standard value used when calculating lot sizes for variable lots.
The lot size is calculated as "Reference Amount for Variable Lot Calculation ÷ Amount per Lot."
For example, setting 1,000,000 means that when the amount is 10,000 (Yen, USD, etc.), 0.01 lots are set; for 100,000, it is 0.1 lots; for 1,000,000, it is 1 lot.
Maximum Lot Size
For variable lots, if the calculated lot size exceeds this value, it will be adjusted to this value.
(In the case of fixed lots, the fixed lot value is set directly without adjustment)
The maximum lot size varies by broker, so please set accordingly.
Multiplier for 1st Gotobi Day Lots
Multiplier applied to the lot size for trading on the 1st Gotobi day (usually the 5th).
If the "Lot Size" input parameter is 0, the variable lot multiplied by the multiplier is used; if greater than 0, that value multiplied by the multiplier becomes the trade lot size.
(Example)
Input parameter lot size: 0.5
Multiplier: 0.8
Trade lot size: 0.5×0.8=0.4
Remarks
If the initial value is 1, the "Lot Size" input parameter or variable lot becomes the trade lot size directly.
(Lot Size×1=Lot Size)
Setting it to 0 results in a trade lot size of 0, meaning no trade.
(Lot Size×0=0)
To avoid trading on specific Gotobi days, set this parameter to 0.
Multiplier for 2nd Gotobi Day Lots
Multiplier applied to the lot size for trading on the 2nd Gotobi day (usually the 10th).
Setting this to 0 means no trade on the 2nd Gotobi day.
Multiplier for 3rd Gotobi Day Lots
Multiplier applied to the lot size for trading on the 3rd Gotobi day (usually the 15th).
Setting this to 0 means no trade on the 3rd Gotobi day.
Multiplier for 4th Gotobi Day Lots
Multiplier applied to the lot size for trading on the 4th Gotobi day (usually the 20th).
Setting this to 0 means no trade on the 4th Gotobi day.
Multiplier for 5th Gotobi Day Lots
Multiplier applied to the lot size for trading on the 5th Gotobi day (usually the 25th).
Setting this to 0 means no trade on the 5th Gotobi day.
Multiplier for Final Gotobi Day Lots
Multiplier applied to the lot size for trading on the final Gotobi day (usually the month's last day).
Setting this to 0 means no trade on the final Gotobi day.
Take Profit Range (Unit: pips)
If set to a value other than 0, a take profit limit order is set according to that value during trading.
For currency pairs against JPY, 1 pip equals 0.01 Yen.
For buy positions, the take profit limit order is set at Trade Price + Take Profit Range; for sell positions, it is set at Trade Price - Take Profit Range.
(Example)
Currency Pair: USD/JPY
Order Type: Buy
Trade Price: 100.00
Take Profit Range: 10
Take Profit Limit Order: 100.10
Stop Loss Range (Unit: pips)
If set to a value other than 0, a stop-loss order is set according to that value during trading.
For currency pairs against JPY, 1 pip equals 0.01 Yen.
For buy positions, the stop-loss order is set at Trade Price - Stop Loss Range; for sell positions, it is set at Trade Price + Stop Loss Range.
(Example)
Currency Pair: USD/JPY
Order Type: Buy
Trade Price: 100.00
Stop Loss Range: 10
Stop Loss Order: 99.90
Take Profit Amount
If set to 1 or more, the unrealized profit and loss during trading is checked.
When the unrealized profit (total of all positions if additional orders exist) reaches the take profit amount, a market order is executed to settle the position at that point.
If the take profit amount is not reached before the trade end time, settlement occurs as usual at the trade end time.
(Example)
Currency Pair: USD/JPY
Account Currency: Yen
Take Profit Amount: 10,000
When the unrealized profit reaches 10,000 Yen or more, a settlement is executed at that point
If the trade end time arrives before reaching 10,000 Yen, settlement occurs at the trade end time
Remarks
Settlements are executed at market.
Hence, actual profit and loss may not match the take profit amount exactly.
The same applies to the stop loss amount below.
Stop Loss Amount
If set to 1 or more, the unrealized profit and loss during trading is checked.
When the unrealized loss (total of all positions if additional orders exist) reaches the stop loss amount, a market order is executed to settle the position at that point.
If the stop loss amount is not reached before the trade end time, settlement occurs as usual at the trade end time.
(Example)
Currency Pair: USD/JPY
Account Currency: Yen
Stop Loss Amount: 20,000
When the unrealized loss reaches 20,000 Yen or more (i.e., profit and loss is -20,000 or less), a settlement is executed at that point
If the trade end time arrives before reaching 20,000 Yen, settlement occurs at the trade end time
Trade Start Time (Hour)
The "hour" value of the time to start trading, i.e., to take a position.
Trade Start Time (Minute)
The "minute" value of the time to start trading.
Trade End Time (Hour)
The "hour" value of the time to end trading, i.e., to close a position.
Trade End Time (Minute)
The "minute" value of the time to end trading.
Remarks
If the trade end time value is later than the trade start time (Trade Start Time < Trade End Time), settlement occurs on the same day as the trade start date.
If not (Trade Start Time ≥ Trade End Time), settlement occurs the next day or later.
(Example)
Trade Start Time: 9:55, Trade End Time: 9:56 Settlement at 9:56 on the trade start date
Trade Start Time: 9:55, Trade End Time: 9:55 Settlement at 9:55 on the day after the trade start date
Trade Start Time: 9:55, Trade End Time: 9:54 Settlement at 9:54 on the day after the trade start date
The term "next day or later" is used because the market may be closed the day after the trade start date.
For example, if the trade start date is Friday, the next day is Saturday.
If the trade end time is later than the market closing time on Saturday, settlement does not occur until the following week.
Chart GMT Offset
The offset (timezone) of the chart relative to GMT.
Set according to your broker.
This value converts the chart time to Japan time.
For example, setting it to 2 means GMT+2, and 7 hours (the difference from Japan time GMT+9) are added to the chart time to convert it to Japan time.
This time is displayed at the top left of the chart.
Daylight Saving Time Type
If this value is "America," then during American daylight saving time (second Sunday of March to first Sunday of November), 1 is added to the "Chart GMT Offset" value.
If it is "Europe," then during European daylight saving time (last Sunday of March to last Sunday of October), 1 is added to the "Chart GMT Offset" value.
If it is "Other/None," no addition is made.
(Example)
Chart GMT Offset: 2
Value "America"3 during American daylight saving time, 2 during American standard time
Value "Europe"3 during European daylight saving time, 2 during European standard time
Value "Other/None" always 2
If your broker follows American daylight saving time, set this to "America."
If it follows European daylight saving time, set this to "Europe."
For other daylight saving times or if none, set this to "Other/None."
For other daylight saving times, manual adjustments are required. Set the "Chart GMT Offset" to the daylight saving offset during daylight saving time and to the standard offset during standard time.
Start Trading the Day Before Gotobi Day
Normally, today's date determines whether it is a trading day, but if this value is true, it changes to the next day (24 hours from the current time).
As a result, trading starts at the trade start time on the day before Gotobi day (displayed as "Trading Day This Month" at the top left of the chart).
If false, trading starts as usual at the trade start time on Gotobi day.
(Example)
Gotobi Day: 5th, Trade Start Time: 23:00, Trade End Time: 9:55
Value trueStart trading at 23:00 on the 4th, settle at 9:55 on the 5th
Value falseStart trading at 23:00 on the 5th, settle at 9:55 on the 6th
Remarks
This parameter aims to enable starting trades before 0:00 on Gotobi day.
If enabled, set the trade start time and trade end time to "Trade Start Time < Trade End Time."
As explained in the "Trade End Time (Minute)" remarks, if "Trade Start Time < Trade End Time," settlement occurs on the trade start date, i.e., the day before Gotobi day.
Start Trading After Trade Start Time
If this value is true, trading can start anytime from the trade start time to the end of the day (23:59:59).
If false, trading can only start within the trade start time period.
(Example)
Trade Start Time: 9:00
Value trueTrading can start between 9:00:00 and 23:59:59
Value falseTrading can start only between 9:00:00 and 9:00:59
If there is movement in the chart