Strategy · Pine Script v6 · On the chart

PF TA Isolate 10 - Typed-Matrix UTC

by pineforge-4pass· code credited to PineForge contributors 2026

PF TA Isolate 10 - Typed-Matrix UTC is a Pine Script v6 strategy designed for engine parity validation.

View on GitHub

GitHub stars1on the repository
Pine versionv6current
Lines of code60
Settings0inputs
LicenceApache-2.0
Last update5 days ago23 Oct 2026

Add It to Your TradingView Chart

  1. 1Copy the scriptPress Copy script above, or the copy button on the code below.
  2. 2Open the Pine EditorOpen a TradingView chart and choose Pine Editor at the bottom of the screen.
  3. 3Paste over the templateCreate a new strategy, select all of the template text and paste. Press Save and give it a name.
  4. 4Add it to the chartPress Add to chart. The trades and results appear in the Strategy Tester tab; adjust the settings with the gear icon.

Source Code

60 lines of Pine Script v6 from validation/matrix-bool-mask-explicit-utc-tz-01/strategy.pine, published under Apache-2.0. Keep the author's credit and licence lines when you reuse it.

strategy.pine
// This Pine Script® code is licensed under Apache-2.0
// SPDX-License-Identifier: Apache-2.0
// © PineForge contributors 2026
//
// PF TA-isolate probe 10 — typed-matrix-01 with explicit hour(time, "UTC")
//
// Purpose: typed-matrix-probe-01-bool-regime-mask uses bare `hour(time)` and
// `dayofweek(time)`, which Pine resolves to `syminfo.timezone` (the EXCHANGE
// timezone, NOT the chart display TZ). For BINANCE:ETHUSDT.P, TV may report
// syminfo.timezone as "UTC" or a non-UTC value depending on TV's symbol
// metadata — engine defaults to "UTC" via its constructor.
//
// This probe pins both sides to "UTC" by passing the timezone explicitly.
// Pine v6: `hour(time, tz_arg)` honours the explicit `tz_arg` regardless of
// syminfo or chart TZ.
//
// Diagnostic:
//   excellent → bug in typed-matrix-01 is engine syminfo_.timezone vs TV
//               syminfo.timezone for BINANCE:ETHUSDT.P. Fix: validator
//               passes BINANCE's syminfo.timezone (whatever TV reports) to
//               engine via syminfo_, separately from chart_timezone_.
//   strong/moderate → bug is in matrix bool dispatch (set/get/transpose) or
//               hotCount accumulator, NOT TZ-related.
//@version=6
strategy("PF TA isolate 10 - typed-matrix UTC", shorttitle="TAI_10_TM_UTC",
     overlay=true, initial_capital=1000000,
     commission_type=strategy.commission.percent, commission_value=0, slippage=0,
     default_qty_type=strategy.fixed, default_qty_value=1, pyramiding=1,
     process_orders_on_close=false)

var matrix<bool> mask = matrix.new<bool>(24, 7, false)

rsiVal = ta.rsi(close, 14)

int h = hour(time, "UTC")
int d = dayofweek(time, "UTC") - 1  // 0..6

if not na(rsiVal) and rsiVal > 60.0 and h >= 0 and h < 24 and d >= 0 and d < 7
    matrix.set(mask, h, d, true)

var matrix<bool> mT  = matrix.new<bool>(7, 24, false)
var matrix<bool> mTT = matrix.new<bool>(24, 7, false)
mT  := matrix.transpose(mask)
mTT := matrix.transpose(mT)

bool sample = matrix.get(mTT, h < 24 ? h : 0, d >= 0 and d < 7 ? d : 0)

int hotCount = 0
for i = 0 to 23
    for j = 0 to 6
        if matrix.get(mTT, i, j)
            hotCount += 1

bool entryCond = hotCount >= 6 and rsiVal > 55.0 and sample
bool exitCond  = not na(rsiVal) and rsiVal < 45.0

if entryCond and strategy.position_size == 0
    strategy.entry("L", strategy.long, qty=1, comment="entry long")
if exitCond and strategy.position_size > 0
    strategy.close("L", comment="exit long")

Overview

PF TA Isolate 10 - Typed-Matrix UTC populates a 24-by-7 boolean matrix tracking high-RSI hours and days using an explicit UTC timezone specification. The matrix is transposed twice to check state consistency before counting total active cells. Long entries trigger when at least six cells are set, RSI exceeds 55, and the current hour and day slot is marked active. Positions close when RSI falls below 45. It overlay-renders on the main price chart, has no user input settings, and lacks a defined stop loss.

Details

Published by

pineforge-4pass on GitHub

Code credit

PineForge contributors 2026, as written in the script's header

Type

Strategy, Pine Script v6

Draws

On the price chart

Category

Oscillators & momentum

Markets

Any symbol

Timeframes

Any timeframe

Risk Notes

  • The strategy enters trades without a stop loss

Topics

algorithmic-tradingbacktestingparitypine-scriptpinescriptquantitative-financetest-corpustradingview

Third-party code. ForexR did not write, test or endorse this script, and the summary above was generated automatically from its code and README. Indicators describe the past, and a strategy's backtest can look better than live trading, especially when a script repaints. Check it in the Strategy Tester and on a demo account before you rely on it.

Similar Pine Scripts

330 stars

2 EMA/SMA + RSI Strategy [Alorse] combines three configurable moving averages with a short-period Relative Strength Index filter. It plots fast, slow, and trend moving averages on the price chart. Long entries trigger when the fast moving average is above the

Strategy v4 TrendOscillators & momentum
Updated 2 months ago · None stated GitHub repository of 2 EMA/SMA + RSI Strategy [Alorse]

Acrypto - Weighted Strategy

by AlbertoCuadra
318 stars

This strategy plots on the price chart and opens long or short positions when a weighted score from MACD, Stochastic RSI, RSI, Supertrend and a moving-average crossover exceeds a user-set trigger. Each component has its own weight and candle delay. Entries can

Strategy v5 TrendOscillators & momentum
Updated 3 years ago · Custom licence GitHub repository of Acrypto - Weighted Strategy
285 stars

Mean Reversion Strategy is an overlay strategy that identifies pullbacks using a long-term EMA, RSI, and candlestick patterns. It generates long signals when a bullish engulfing candle forms below the EMA while RSI is oversold, and short signals when a bearish

Strategy v4 Mean reversionCandlestick patterns
Updated 3 years ago · None stated GitHub repository of Mean Reversion Strategy

MACD Strategy

by TradersPost
218 stars

This overlay strategy is built around MACD inputs for a fast average, a slow average, and a signal line. Comments say the script keeps MACD values available and can draw a histogram and zero line in a separate pane, with an optional overlay on price. Settings

Strategy v6 Oscillators & momentumMoving averages
Updated 3 months ago · None stated GitHub repository of MACD Strategy

255 EMA Strategy

by hasnocool
106 stars

255 EMA Strategy combines an exponential moving average with Average True Range bands and standard MACD crossovers to generate entry signals. Drawn directly on the price chart, it plots the central 255 EMA along with upper and lower volatility envelopes. Trade

Strategy v4 Moving averagesOscillators & momentum
Updated 2 years ago · GPL-3.0 GitHub repository of 255 EMA Strategy

More strategys

Trade Your Charts With a Regulated Broker

Compare brokers that connect to TradingView, with spreads, minimum deposits and leverage side by side.

Compare brokers