Trade Assistant Risk Calculator MT5
Trade Assistant Risk Calculator is an all-in-one floating trading panel Expert Advisor for MetaTrader 5, built for professional manual traders. It combines visual chart trading, automatic risk calculation, and advanced position management in one compact interface.
Stop calculating lot sizes manually. Stop guessing your Risk:Reward ratio. Drag the planning lines on the chart and the EA calculates the exact lot size for your selected risk percentage, equity, fixed-money risk, or fixed-lot workflow.
Important Notes
- This product is an Expert Advisor (EA), not an indicator. Attach it to any chart to activate the floating panel.
- Algo Trading must be enabled in MetaTrader 5 for the EA to place orders and manage positions.
- The panel is draggable from its title bar and can be minimized with the title-bar minus button.
- Works on live and demo accounts. Because this EA relies on chart events, test it on a demo account rather than the Strategy Tester.
- Supports both Hedging and Netting accounts.
Core Features
1. Visual Order Placement & Interactive Chart Overlays
- Drag-to-Trade Planning: Entry, Stop Loss, and Take Profit planning lines appear directly on the chart. Move the lines to define your setup visually.
- Instant Risk Calculation: As you move the Stop Loss line, the EA recalculates lot size to keep your selected risk constant.
- Live R:R Display: Adjust the Take Profit line and see the Risk:Reward ratio update in real time.
- Market & Pending Orders: Place market orders or pending orders (Buy/Sell Limit and Buy/Sell Stop) from the chart overlay. To reduce accidental market entries, the Entry card now defaults to Pending mode. If VPend is enabled, the Pending command creates a virtual pending order instead of a broker pending order. Pending orders support configurable expiry timers.
- Order Confirmation: Optional Confirm Trade dialog shows order type, lots, risk, margin, entry, SL, and TP before execution. Use Submit to send the order.
- Interactive Drag Bars: Entry, TP, SL, and active partial levels have floating bars showing price, pips distance, and money value. Drag the bar instead of the thin chart line.
- Entry Bar Quick Actions: B/S flips direction, Cmd executes, M/S switches market or pending mode, R cycles risk mode, and X removes the planning lines.
- Color-Shaded Profit/Loss Zones: Semi-transparent green and red zones between Entry, TP, and SL make the reward and risk areas easy to see at a glance.
- Order State Colors: Filled positions, broker pending orders, and virtual pending orders use different chart-card colors and markers. Positions filled from virtual pending orders are marked with [VP].
- Live Floating P/L Badges: Filled positions show real-time floating P/L in both money and pips, including swap and commission.
- Apply-to-Positions Buttons: The "L" buttons on the main TP / SL bars apply the current planned TP / SL price to all open positions on the current symbol as broker-side TP / SL.
- Quick Trade Options: OCO, Hide SL/TP, and VPend toggles are available directly on the Trade tab. Hide SL/TP and VPend affect new orders only and never change already-existing tickets.
- Per-Ticket Action Menu: Every position, broker pending order, and virtual pending order has a chart-card menu. Depending on ticket type, you can close, reverse, partial-close, edit broker or virtual SL/TP, open Edit Parts, configure per-ticket BE / Trail, run Parts: Copy Applied Panel, or use Parts: Disable This Ticket.
- Timeframe Persistence: Planning lines remain in place when you change chart timeframes or chart parameters.
2. Buy/Sell Direction Flip & Smart Mirroring
- One-Click Direction Flip: The B/S button flips the entire setup between Buy and Sell.
- Automatic Mirror: SL and TP mirror around the entry price, preserving the geometry of your setup.
- Partial Lines Follow: Active TP1–TP10 and SL1–SL10 levels move to the correct side when the direction flips.
- Auto-Flip on Drag: Dragging TP or SL across entry flips the trade direction and mirrors the opposite line.
3. Professional Risk Management
- 4 Risk Modes: % Balance, % Equity, Fixed Money, and Fixed Lots. Each mode remembers its previous value.
- Pips or Price Input: Work with absolute price levels or pip distances from entry.
- Spread Filter: Block new trades when spread exceeds your configured maximum.
- Custom Comments: Add an order comment from the Trade tab.
- Daily Loss Lock: Stop new trading, and optionally close positions, when daily loss limits are reached. Lock can apply to the current symbol or all symbols and resets on daily rollover.
4. PARTS Tab — Multi-Level Partial Close System
- Up to 10 TP Levels and 10 SL Levels: Configure TP1–TP10 and SL1–SL10 with independent active state, pips distance, and close percentage.
- Draft / Apply Workflow: Editing PARTS values or toggling active buttons creates a draft first. The live planning state changes only when you click Apply. If there are unsaved edits, the panel shows APPLY * and a pending-changes prompt.
- Active Buttons Are Draft Controls: Turning TP1–TP10 or SL1–SL10 active on/off does not immediately draw or remove lines. Click Apply to commit the change.
- Safe Symbol Scope: PARTS defaults to Cur Sym (blue) and applies only to the current chart symbol. Switching to All Sym requires a second confirmation click (Confirm All uses the warning color, All Sym uses red) and is session-only. Because pip scales differ widely between instruments such as EURUSD, XAUUSD, and indices, All Sym never applies the current chart's global fixed-pip levels directly to other symbols; non-current symbols act only when that ticket has an explicit per-ticket PARTS setup.
- Chart Visualization: Applied active partial levels draw dotted lines with drag bars showing price, pips, money value, and close percentage.
- Drag Applied Levels: Dragging an already-applied partial bar updates that live planning value while preserving smart clamps.
- Smart Clamping: Partial TP levels stay on the profit side, partial SL levels stay on the loss side, and each partial level keeps at least a 1 pip gap from the full TP or SL distance.
- Input Validation: Invalid pips values turn red and are kept for correction. Invalid draft values are not applied until fixed.
- Per-Ticket Inheritance / Override Model: Existing positions, broker pending orders, and virtual pending orders inherit the applied panel settings until you explicitly configure that ticket. Explicit disabled state is also an override and blocks later panel changes from re-enabling that ticket.
- Per-Ticket Edit Parts: Each ticket can open its own Edit Parts sub-panel with Apply / Back semantics, ticket-level validation, and independent TP1–TP10 / SL1–SL10 values. Closing or Back discards temporary edits; Apply saves the ticket override.
- Copy or Disable One Ticket: Parts: Copy Applied Panel copies the current applied PARTS panel to one ticket. Parts: Disable This Ticket disables that ticket's partial structure without touching other tickets.
- Placed Ticket Snapshots: Filled positions, broker pending orders, and virtual pending orders can keep independent TP/SL partial structures, and pending-ticket settings migrate to the filled position when triggered.
- Lines OFF Reset: Turning Lines off resets the PARTS panel planning fields and master toggles for the next setup; already-placed tickets keep their own snapshots.
- Proportional Money Display: Each partial level shows money value based on that level's close percentage, not the full position size.
- Dynamic Spacing: Auto-calculate evenly spaced TP and SL partial levels with independent dynamic-spacing controls.
5. BE Tab — Breakeven & Pending Management
- Auto Breakeven: Move SL to breakeven after a configurable profit trigger, with adjustable offset.
- Auto Offset: Estimate spread and commission costs from history to calculate a practical breakeven offset.
- Per-Ticket BE Overrides: Positions, broker pending orders, and virtual pending orders can have dedicated BE settings. Pending-ticket settings migrate to the filled position. Explicit ON or OFF blocks the global BE panel from overriding that ticket.
- Broker Pending Limit Trail: Trail BUY_LIMIT / SELL_LIMIT broker pending orders closer to market as price moves favorably, while preserving pending expiry.
- Broker Pending Stop Trail: Trail BUY_STOP / SELL_STOP broker pending orders. Virtual pending orders are not moved by this broker pending trail module.
- OCO: When one pending order on the same symbol triggers, other broker pending orders and virtual pending orders on that symbol are canceled.
- Hide SL/TP: New market orders or broker pending orders can be sent without broker-side SL/TP while the EA manages virtual SL/TP locally. Existing tickets are not changed by the panel toggle.
- Virtual Pending Orders: VPend keeps pending entries local until triggered. When triggered, the EA converts the setup to a stealth market position with virtual SL/TP and migrates ticket-specific PARTS / BE / Trail settings.
- Persistence Model: Virtual SL/TP, PARTS panel settings, ticket partial snapshots, and ticket BE / Trail overrides are restored across EA recompile, version upgrade, and remove + reattach; however, the PARTS All Sym scope is not auto-persisted and returns to the safer Cur Sym scope after reload. Untriggered virtual pending orders are restored from hidden chart mementos on the same chart window only, so a brand-new chart starts clean.
6. TRAIL Tab — 8-Mode Trailing Stop Engine
- 8 Trail Modes: NONE, PIPS, HI/LO, MA, SAR, ATR, PARTIAL, and FRACTALS.
- Universal Settings: Start, Distance, and Step control when trailing activates and how often it updates.
- Per-Ticket Fixed-Pip Trail: Positions, broker pending orders, and virtual pending orders can define ticket-level trail settings. Pending-ticket settings migrate to the filled position. Explicit disabled state blocks global trailing for that ticket.
- Hidden SL/TP Safe: Breakeven and trailing updates preserve the other hidden SL/TP leg when modifying virtual protection.
7. CLOSE Tab — Bulk Position & Pending Management
- Close/Cancel All: Close all positions and cancel all broker pending orders and virtual pending orders across all symbols.
- Close + Pending Symbol: Close current-symbol positions and cancel that symbol's broker pending orders and virtual pending orders.
- Cancel Pending: Cancel all broker pending orders and virtual pending orders.
- Close Buy / Sell / Profit / Loss: Close buy positions, sell positions, profitable positions, or losing positions according to the selected rule.
- Partial Close: Close a configurable percentage of each open position with one click.
- Auto-Close Targets: Set profit or loss targets in money or percent for the account or current symbol.
- Trading Locks: Lock all trading or lock only the current symbol to prevent impulsive entries.
8. INFO Tab — Account Dashboard
- Live Account Data: Balance, Equity, Floating P/L, Free Margin, and Margin % update in real time.
- Position Summary: See total positions, buy lots, sell lots, and current-symbol P/L.
- Daily Statistics: Day-start equity, today's P/L, and lock status reset automatically at daily rollover.
- Symbol Switcher: Configure up to 6 symbols for one-click chart switching through InpSwitcherSymbols .
- Hotkey Reference: The panel shows quick keyboard shortcuts such as Close/Cancel All, Close/Cancel Symbol, Cancel Pending, Trail, and BE.
9. Tools
- Screenshot: Capture a full chart screenshot with one click.
- Price Alert Line: Draw an alert line and receive audio / visual alerts when price crosses it.
- Cancel-at-Level: Draw a cancel level. When price reaches it, the EA cancels broker pending orders and virtual pending orders on the current symbol.
10. Entry Line Proportional Drag
- Dragging the Entry line moves SL, TP, and active partial levels by the same amount, preserving distances and Risk:Reward geometry.
Hotkeys
- B / S: Buy / Sell Market
- U / D: Buy / Sell Pending
- C: Close positions and cancel all pending orders
- X: Close current-symbol positions and cancel its pending orders
- P: Cancel all broker and virtual pending orders
- L: Lock current-symbol trading
- A: Lock all trading
- T: Toggle trailing stop
- E: Toggle breakeven
Input Parameters
- Risk Settings: default risk, fixed money risk, R:R, and max spread.
- Stealth Settings: virtual pending and virtual SL/TP.
- Management: BE, trailing, OCO, pending expiry, Magic Number, and symbol scope.
- Auto-Close Rules: profit/loss targets in money or percent.
- Time Filters: trading sessions, trading days, and crypto-weekend support.
- Visual Settings: line colors and panel position.
- Symbol Switcher: up to 6 comma-separated symbols.
Why Choose Trade Assistant Risk Calculator?
Whether you need fast scalping execution or precise swing-trade management, this EA handles the calculations and ticket management so you can focus on price action. With visual planning, risk-based sizing, virtual protection, virtual pending orders, per-ticket overrides, 10-level TP and SL partials, and an 8-mode trailing engine, it helps enforce disciplined trade management.
Take control of your trading with Trade Assistant Risk Calculator.
