**QUANTTOWER** LINEBREAK CHART BASIC STRATEGY: Directional Flow Strategy – Technical Specification Strategy Overview This strategy is a directional flow system that evaluates real-time market pressure at specific structural price levels derived from each bar’s volume distribution. The strategy does not attempt to predict future price. Instead, it evaluates order-flow pressure when price interacts with predefined trigger levels and executes trades when pressure confirms a high-probability move. A custom indicator called MarketPressureScore acts as the decision engine. \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ Core System Components 1\. Market Pressure Engine The system calculates a single value called: MarketPressureScore This value measures the strength and direction of recent order flow within a short time window. Interpretation: Positive value → buying pressure Negative value → selling pressure Near zero → weak or neutral pressure Trades are only permitted when the pressure magnitude exceeds a predefined threshold. \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 2\. Structural Price Trigger System The Market Pressure indicator is not evaluated continuously. Instead, it is evaluated only when price reaches specific structural trigger levels. These trigger levels are derived from: the open price of each new bar histogram cluster extremes from prior bars \########################################################################## Trigger Level 1 – New Bar Open Every time a new bar opens, the following occurs: Evaluate MarketPressureScore If pressure meets the required threshold, the system may initiate a position depending on the current directional structure. \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 3\. Directional Structure Definition Directional structure is determined using the most recent completed bar. Upward Direction: At least one completed bar closes higher than the previous bar. Downward Direction: At least one completed bar closes lower than the previous bar. This directional state determines which trade direction is allowed. **NOTE: FOR "ALL POSITIONS"...SHORT MARKET ORDERS CAN ONLY BE INITIATED IF THE PRICE IS ABOVE THE OPEN PRICE IN A UPWARD DIRECTION \& LONG MARKET ORDERS CAN ONLY BE INITIATED IF PRICE IS BELOW THE OPEN PRICE IN DOWNWARD DIRECTION!!!!!** \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 4\. Trigger Levels During Upward Direction When an upward direction is detected: The strategy creates trigger levels using: Highest histogram price from each prior bar Each time price crosses one of these levels, the system performs: Evaluate MarketPressureScore If pressure confirms the condition, the strategy may open a position. Allowed Trade Direction During an upward directional state, the system only takes: SHORT positions Therefore: Trigger events \+ confirmed pressure → initiate SHORT trade These trades are effectively momentum exhaustion entries against the most recent upward structure. **NOTE: FOR "ALL POSITIONS"...SHORT MARKET ORDERS CAN ONLY BE INITIATED IF THE PRICE IS ABOVE THE OPEN PRICE IN A UPWARD DIRECTION \& LONG MARKET ORDERS CAN ONLY BE INITIATED IF PRICE IS BELOW THE OPEN PRICE IN DOWNWARD DIRECTION!!!!!** \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 5\. Trigger Levels During Downward Direction When a downward direction is detected: The strategy creates trigger levels using: Lowest histogram price from each prior bar Each time price crosses one of these levels, the system performs: Evaluate MarketPressureScore If pressure confirms the condition, the strategy may open a position. Allowed Trade Direction During a downward directional state, the system only takes: LONG positions Therefore: Trigger events \+ confirmed pressure → initiate LONG trade These trades act as momentum exhaustion entries against the most recent downward structure. **NOTE: FOR "ALL POSITIONS"...SHORT MARKET ORDERS CAN ONLY BE INITIATED IF THE PRICE IS ABOVE THE OPEN PRICE IN A UPWARD DIRECTION \& LONG MARKET ORDERS CAN ONLY BE INITIATED IF PRICE IS BELOW THE OPEN PRICE IN DOWNWARD DIRECTION!!!!!** \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 6\. Optional Partial Profit Mechanism An optional feature may use opposite histogram extremes as partial exit points. Concept: When holding a long position: If price crosses high histogram levels, the system may trigger a partial take-profit. When holding a short position: If price crosses low histogram levels, the system may trigger a partial take-profit. This feature should remain configurable, because: it can smooth the equity curve but it may reduce total profit during extended trends **NOTE: FOR "ALL POSITIONS"...SHORT MARKET ORDERS CAN ONLY BE INITIATED IF THE PRICE IS ABOVE THE OPEN PRICE IN A UPWARD DIRECTION \& LONG MARKET ORDERS CAN ONLY BE INITIATED IF PRICE IS BELOW THE OPEN PRICE IN DOWNWARD DIRECTION!!!!!** \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 7\. Trade Execution Logic At every trigger level the following process occurs: 1\. Price crosses trigger level 2\. Calculate MarketPressureScore 3\. Compare score against threshold 4\. Check directional state 5\. If conditions align → execute trade Example: Upward direction detected Price crosses histogram high Pressure confirms selling → Open SHORT position Example: Downward direction detected Price crosses histogram low Pressure confirms buying → Open LONG position **NOTE: FOR "ALL POSITIONS"...SHORT MARKET ORDERS CAN ONLY BE INITIATED IF THE PRICE IS ABOVE THE OPEN PRICE IN A UPWARD DIRECTION \& LONG MARKET ORDERS CAN ONLY BE INITIATED IF PRICE IS BELOW THE OPEN PRICE IN DOWNWARD DIRECTION!!!!!** \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 8\. Strategy Flow Summary System operation follows this sequence: New bar opens   ↓ Determine directional structure   ↓ Create histogram trigger levels from prior bars   ↓ Price crosses trigger level   ↓ Evaluate MarketPressureScore   ↓ If pressure confirms AND trade direction allowed   ↓ Execute position   ↓ Optional partial exit at opposing histogram levels \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 9\. Core Strategy Principles The strategy combines three decision layers: Structural direction Volume distribution extremes Real-time market pressure Trades are only executed when all three components align. This design ensures the system reacts only to structural price interactions supported by real order flow. \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ MARKET PRESSURE SCORE EVALUATION Engine: Before your Line Break system enters a trade, check if real market pressure exists. If pressure is weak → do not trade If pressure is strong → allow the trade This becomes a single number filter your program reads. \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 1\. Concept in One Sentence The program measures how fast price is moving and in what direction over the last 12 seconds. This produces one variable: MarketPressureScore \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 2\. Data the Program Needs The programmer only needs: Tick price Tick timestamp Optional (but better): Trade volume Your platform already provides tick data. \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 3\. Use Last 12 Seconds of Ticks Every time a new tick arrives: Store all ticks that occurred in the last 12 seconds. Example structure: struct Tick {   double price;   long timestamp; } STORE THEM IN A LIST Remove any ticks where: tick.timestamp < currentTime - 12 seconds This keeps only the most recent 12 seconds of market activity. \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 4\. Calculate Price Change Measure how much price moved. priceChange = lastTick.price - firstTick.price EXAMPLE: Tick1 = 2012.4 Tick10 = 2013.1 priceChange = 0.7 \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 5\. Calculate Time Duration timeDuration = lastTick.timestamp - firstTick.timestamp EXAMPLE: 12 seconds (or slightly less depending on tick timing) \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 6\. Calculate Tick Velocity Velocity tells you how fast price is moving. velocity = priceChange / timeDuration EXAMPLE: 0.7 / 12 = 0.058 \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 7\. Calculate Direction Direction is simply: if(priceChange > 0) direction = +1 else direction = -1 \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 8\. Market Pressure Score Combine velocity and direction. MarketPressureScore = velocity \* direction EXAMPLE: Fast buying = +0.12 Fast selling = -0.10 Slow movement = 0.01 \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 9\. Entry Filter Your Line Break strategy already detects entries. Before executing the trade: Add one check. if (abs(MarketPressureScore) > PressureThreshold)   AllowTrade() else   BlockTrade() EXAMPLE THRESHOLD: 0.05 \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 10\. Performance Cost Very low. Only calculations: Ticks from last 12 seconds 3 numbers 1 division It can run thousands of times per second. \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ 11\. Simple System Flow Program becomes: Tick arrives ↓ Update ticks from last 12 seconds ↓ Calculate MarketPressureScore ↓ LineBreak signal appears ↓ Check MarketPressureScore ↓ If strong → execute trade If weak → ignore signal