Amaterasu FX
- Experts
-
Michael Prescott Burney
I am a professional trader and Expert Advisor developer focused on building high-performance, risk-driven systems for MetaTrader 5. - Version: 5.0
- Updated: 1 July 2026
Amaterasu EA for USDJPY H1 — Portfolio System Powered by Expert Advisor HQ
Amaterasu EA is a professional-grade portfolio Expert Advisor for USDJPY H1, built on the Expert Advisor HQ Portfolio Framework used across the entire EAHQ product line. It combines multiple independent internal strategies into a single EA instance, with a unified risk engine, protection architecture, and real-time analytics dashboard. Attach it to a USDJPY H1 chart, configure your preferred risk parameters, and the framework manages entries, exits, and protections in a fully automated, transparent environment.
Core Concept
Instead of running many separate robots, Amaterasu EA acts as a multi-strategy portfolio system dedicated to USDJPY H1. Each internal strategy produces signals into a common pipeline, while a single execution engine manages orders, trailing stops, and protection layers. This design keeps the operational behavior consistent across brokers and conditions, while allowing you to manage all trades from one EA and one dashboard.
Key Features
Amaterasu EA inherits the full Expert Advisor HQ Portfolio Framework feature set:
• Multi-strategy portfolio engine for USDJPY H1
All trades originate from internal strategy slots mapped by magic numbers, allowing the EA to track and display each component separately in the dashboard while executing under one symbol and timeframe.
• Layered protection architecture
Three independent protection layers stack together: Entry Protections (spread, max positions, max lots), Daily Protections (MaxDailyLoss and Max_Daily_DD from intraday peaks), and Account Protections (Min_Equity, MaxEquity_DD, and Max_Equity) for critical equity events. Triggered protections close positions and either suspend new entries until reset or remove the EA entirely, depending on the layer.
• Professional order execution engine
Every order is pre-checked with OrderCheck and sent through a retry engine with exponential backoff to handle requotes, price changes, and transient broker errors. The EA automatically negotiates the correct MT5 fill policy across IOC, FOK, RETURN, and BOC and persists the successful one for future orders, improving robustness across different brokers.
• Built-in news filter using MT5 economic calendar
The integrated news filter monitors upcoming events for configured currencies and blocks new entries in a user-defined window before and after medium- and high-impact news. This allows Amaterasu EA to stand aside during the most volatile periods while continuing to manage existing positions and keep the dashboard updated.
• TradingView-style real-time analytics dashboard
The EA renders a hardware-accelerated CCanvas dashboard directly on the chart, showing equity, balance, floating P&L, open position count, equity sparkline, 1D/7D/30D performance, and per-strategy breakdown. The panel runs in a lightweight tick-refresh mode for live metrics and a full bar-refresh mode for complete analytics recomputation.
• On-chart arrows, projections, and overlays
Every trade entry is marked by a permanent directional arrow (green for buys, red for sells) with a tooltip describing direction, price, SL, TP, and magic number. For open positions, the EA draws entry lines and visual profit/loss zones from entry to TP and SL, making each trade’s risk–reward profile immediately visible on the chart.
How Amaterasu EA Operates
The EA processes every tick and every new bar through a structured operational pipeline:
On every tick, the account protection state is updated and critical limits are checked; if a critical condition is met, the EA closes positions and may remove itself from the chart depending on the protection. The dashboard receives a lightweight refresh approximately every two seconds, updating equity, balance, spread, and P&L, while the news data cache is periodically refreshed when the filter is active.
On each new bar, the EA performs a full dashboard refresh, recomputes analytics, rebuilds trade projections, and then applies the session gate for Amaterasu’s configured trading window. If the current bar falls outside the allowed session, signal processing is skipped and the dashboard shows OUT OF SESSION, but the monitoring layer remains active.
When conditions are valid, the Amaterasu strategy layer generates a list of internal Signal objects, each carrying direction, scope (entry or exit), stop-loss pips, take-profit pips, trailing stop flag, and reverse flag. These signals are dispatched through the framework’s ManageSignal dispatcher, which decides whether to open, close, modify, or trail positions while respecting all pre-flight protection gates.
Protection Systems
Amaterasu EA exposes the same protection input set as every Expert Advisor HQ portfolio product, with recommended values provided in the user manual and product documentation. All protections operate independently and report their status directly on the dashboard and into the MT5 Experts journal.
1. Entry Protections (pre-trade gates)
These checks run before any entry order is sent:
- Max_Spread — maximum allowed spread in points; if current spread exceeds this value, the entry is skipped and logged.
- Max_OpenPos — maximum number of open positions for this EA; once reached, further entries are blocked until a position closes.
- Max_OpenLots — maximum total lot volume across all positions owned by this EA; new entries are blocked when the ceiling is reached.
2. Daily Protections (session-level)
Daily protections monitor losses from the current day’s balance and equity peaks:
- MaxDailyLoss — closes all open positions and suspends new entries when the currency loss from today’s balance peak reaches the configured amount.
- Max_Daily_DD — closes positions and suspends entries when intraday equity drawdown from the day’s peak reaches the specified percentage.
- Daily_Reset — terminal-time hour when daily metrics and entry suspension reset, allowing the system to resume automatically.
3. Account Protections (critical shutdown)
Account-level protections handle significant account events:
- Min_Equity — absolute equity floor; when reached, the EA closes all positions, destroys the dashboard, and removes itself from the chart.
- MaxEquity_DD — maximum drawdown from all-time equity peak, expressed as a percentage; when hit, the EA performs a full protection shutdown and requires manual restart.
- Max_Equity — equity ceiling; when reached, the EA locks in gains by shutting down after closing current positions.
Trade Management
Each trade decision in Amaterasu EA is expressed as a Signal object before being sent to the broker, ensuring that strategy logic separates cleanly from execution logic. Signals specify the magic number, scope, direction, SL/TP distances in pips, a trailing stop flag, and an optional reverse-on-opposite flag.
Stop loss and take profit levels are calculated from the current Bid (for buys) or Ask (for sells) using pip-based distances, then automatically adjusted if needed to respect the broker’s minimum stop level. Setting either distance to zero disables that level entirely, which can be useful for basket-style or session-based exit logic.
When the trailing stop is enabled for an exit signal, the framework uses a bar-high/bar-low method: for buys, the stop trails below the previous bar’s low; for sells, it trails above the previous bar’s high. The trailing stop only moves in the profitable direction and will close the position immediately if the computed stop would cross the current market price, rather than waiting for the broker’s stop execution.
Analytics Dashboard
Amaterasu EA includes the full EAHQ dashboard, implemented as a bitmap canvas using the MT5 CCanvas library. The dashboard provides an at-a-glance view of account state and Amaterasu’s performance without leaving the chart.
The expanded view shows a header with symbol, timeframe, and LIVE/IDLE session state; equity and balance tiles; floating P&L and position count; rolling equity sparkline with drawdown from peak; 1D/7D/30D P&L statistics; and an Active Strategies table listing direction, lots, and live P&L for each open position. The status footer reports system state (READY, NEWS HOLD, OUT OF SESSION, PROTECTION), current spread in points, and the EA’s base magic number.
A minimized mode collapses the panel to a compact header showing just logo, floating P&L, and open position count, ideal when screen space is limited. A gear icon opens a settings overlay with live toggles for equity sparkline, strategy breakdown, trade projections, and signal arrows so you can adjust visualization without reattaching the EA.
Inputs and Configuration
All Expert Advisor HQ portfolio EAs share the same input structure, so once you learn it for one product, you can operate Amaterasu EA and future EAHQ tools with the same workflow. Below is an overview of the key parameter groups; refer to the included user manual and product page for the recommended USDJPY H1 settings and example configurations.
General
Entry_Amount defines the fixed lot size per trade; the EA does not auto-scale position size, so set this value to match your account size and risk tolerance. Base_Magic_Number provides the root identifier for Amaterasu’s trades; the framework derives individual strategy magic numbers by combining this base with strategy indices, and each EA instance on the same account should use a unique base.
Entry / Daily / Account protections align with the protection systems described above and should be configured before enabling live auto-trading. The EA ships with protections disabled by default (zero values) to allow flexible testing; in live trading, you are encouraged to enable MaxDailyLoss, Max_Daily_DD, Min_Equity, and MaxEquity_DD according to your risk plan.
News filter parameters control which currencies are monitored, and how many minutes before and after medium and high impact events the EA blocks new entries. Because Amaterasu EA trades USDJPY, you typically configure News_Currencies to include at least USD and JPY, and optionally other correlated currencies if desired.
Statistics and visuals inputs toggle per-position statistics, historical performance analytics, and dashboard behavior, including theme (dark/light), corner anchoring, scale, and whether to darken the chart to a TradingView-style palette. Chart arrows, projections, equity sparkline, and the per-strategy table can be enabled or disabled both from inputs and from the in-dashboard gear menu, depending on your layout preferences.
Installation and Deployment
Installation follows the standard MT5 procedure for Market EAs. After downloading Amaterasu EA to your terminal, open File → Open Data Folder in MetaTrader 5, navigate to MQL5/Experts , and ensure the .ex5 file is present; then refresh the Navigator so the EA appears under Expert Advisors.
Enable automated trading globally via Tools → Options → Expert Advisors → Allow automated trading, and activate the Algo Trading toolbar button. Drag Amaterasu EA onto a USDJPY H1 chart, confirm Allow live trading is checked on the Common tab, configure your inputs (lot size, protections, news filter, visuals), and click OK to start the system.
For uninterrupted 24/5 operation, it is recommended to host your MT5 terminal on a low-latency VPS located close to your broker’s trading servers. This reduces the risk of missed bars, platform restarts, or connectivity issues interfering with Amaterasu’s trade management logic.
Best Practices for Using Amaterasu EA
Before switching to real capital, run Amaterasu EA on a demo account for at least 2–4 weeks on USDJPY H1 to observe its behavior across different volatility regimes and news events. During this period, monitor the MT5 Experts and Journal tabs to become familiar with protection messages, skipped entries, and dashboard status transitions.
Configure Max_Spread based on your broker’s typical USDJPY spread during normal hours, usually around 1.5–2 times the average, to filter genuine spread spikes while avoiding unnecessary missed entries. Align Daily_Reset with your broker’s server day-start hour so that daily protections reset at the intended boundary.
If you run multiple EAHQ EAs on the same account, assign each one a unique Base_Magic_Number and never change this value while positions are open. Changing the base magic with open trades causes the EA to lose tracking of its positions and they will no longer be managed or closed by the framework.
Troubleshooting
If Amaterasu EA appears to be idle or is not opening trades, first verify that Algo Trading is enabled, the dashboard is showing READY, and the current bar is inside the system’s trading session. Common causes of no entries include spread above Max_Spread, news filter windows (NEWS HOLD), daily protections in effect, Max_OpenPos or Max_OpenLots limits reached, or simply the absence of a valid strategy signal on recent bars.
Unexpectedly closed positions usually originate from legitimate exits: a strategy exit signal, trailing stop crossing the market price, or the activation of a daily or account protection. Review the MT5 Experts tab around the close timestamp to see the exact reason; the EA logs protection triggers, fill-type negotiation messages, and retry attempts for transparency and easier debugging.
Support, Updates, and Disclaimer
All Expert Advisor HQ customers receive direct developer support through the MQL5 product page private messages and benefit from the Code Guardian Program, which provides ongoing compatibility reviews and framework updates as MetaTrader 5 evolves. Updates are distributed through the MQL5 Market mechanism, and existing customers receive them automatically.
Amaterasu EA is a software tool for automated trading on MetaTrader 5 and is not a financial adviser, investment vehicle, or guaranteed profit-generating system. Trading forex and other leveraged instruments entails substantial risk of loss; past performance in backtests or live trading does not guarantee future results, and you remain fully responsible for all trading decisions and risk management on your account.
