0 beğenilme 0 beğenilmeme
183 kez görüntülendi
İyi günler kolay gelsin...

Mevcutta kullanmış olduğum Tradingview osilatörünü matriks hisse taramasına dönüştürebilirmiyiz.

 

//@version=5
indicator('[blackcat] L3 Banker Fund Flow Trend Oscillator', overlay=true)

// Functions
xrf(values, length) =>
    r_val = float(na)
    if length >= 1
        for i = 0 to length by 1
            if na(r_val) or not na(values[i])
                r_val := values[i]
                r_val
    r_val

xsa(src, len, wei) =>
    sumf = 0.0
    ma = 0.0
    out = 0.0
    sumf := nz(sumf[1]) - nz(src[len]) + src
    ma := na(src[len]) ? na : sumf / len
    out := na(out[1]) ? ma : (src * wei + out[1] * (len - wei)) / len
    out

// Set up a simple model of banker fund flow trend
fundtrend = (3 * xsa((close - ta.lowest(low, 27)) / (ta.highest(high, 27) - ta.lowest(low, 27)) * 100, 5, 1) - 2 * xsa(xsa((close - ta.lowest(low, 27)) / (ta.highest(high, 27) - ta.lowest(low, 27)) * 100, 5, 1), 3, 1) - 50) * 1.032 + 50
// Define typical price for banker fund
typ = (2 * close + high + low + open) / 5
// Lowest low with mid term fib # 34
lol = ta.lowest(low, 34)
// Highest high with mid term fib # 34
hoh = ta.highest(high, 34)
// Define banker fund flow bull bear line
bullbearline = ta.ema((typ - lol) / (hoh - lol) * 100, 13)
// Define banker entry signal
bankerentry = ta.crossover(fundtrend, bullbearline) and bullbearline < 25

// Initialize arrays to store the indices and prices of the last 5 bankerentry signals
var float[] entry_prices = array.new_float(5, na)
var int[] entry_indices = array.new_int(5, na)

if bankerentry
    array.shift(entry_prices)
    array.shift(entry_indices)
    array.push(entry_prices, close)
    array.push(entry_indices, bar_index)

// Draw lines for the last 5 bankerentry signals
for i = 0 to array.size(entry_prices) - 1 by 1
    if not na(array.get(entry_prices, i))
        line.new(x1=array.get(entry_indices, i), y1=array.get(entry_prices, i), x2=array.get(entry_indices, i) + 10, y2=array.get(entry_prices, i), xloc=xloc.bar_index, extend=extend.right, color=color.white, style=line.style_dashed, width=1)

// Determine if the price has crossed above the rectangle
var bool crossed_above = false
if array.size(entry_prices) >= 2
    crossed_above := high > array.get(entry_prices, array.size(entry_prices) - 2)
    crossed_above

// Draw rectangle between the last two entry prices with dynamic color
if array.size(entry_prices) >= 2
    var box rect_id = na
    if not na(rect_id)
        box.delete(rect_id)
    rect_color = crossed_above ? color.green : color.red
    rect_id := box.new(left=array.get(entry_indices, array.size(entry_indices) - 2), top=array.get(entry_prices, array.size(entry_prices) - 1), right=bar_index, bottom=array.get(entry_prices, array.size(entry_prices) - 2), border_color=rect_color, border_width=2, bgcolor=color.new(rect_color, 80))
    rect_id

 

Burada indikatörde oluşan kutunun üstüne çıkan hisseleri tarayabilmek isityorum. ( gün, 180 dk, 240 dk)  ile 5 adet giriş sinyali var bu giriş sinyallerini de değer olarak görmek istiyorum ( ne yapmam lazım ) uygunsa bu 5 giriş sinyalinde bulunan hisseleri ayrı ayrı tarayabilmek istiyorum. ( nereyi değiştireceğimi bulamadım)  İyi çalışmalar...
Analizler kategorisinde (24 puan) tarafından | 183 kez görüntülendi

2 Cevaplar

0 beğenilme 0 beğenilmeme
Merhabalar,

Farklı programlama diline hakim olmadığımızdan maalesef olumlu dönüş sağlayamıyoruz

iyi çalışmalar
(28,508 puan) tarafından
0 beğenilme 0 beğenilmeme
Matriks Explorer için kullanabileceğiniz formül, TradingView'da kullanılan Pine Script'teki bazı işlevlerin Matriks Explorer'ın formül yapısına dönüştürülmesi ile oluşturulabilir. Aşağıda, "L3 Banker Fund Flow Trend Oscillator" formülünü Matriks Explorer'da kullanılabilir hale getirilmiş haliyle sunuyorum:

// Gerekli parametreler
SET ClosePrice = KAPANIS;
SET LowPrice = ENDUŞUK;
SET HighPrice = ENYUKSEK;
SET OpenPrice = ACILIS;

// Fonksiyonlar yerine geçecek hesaplamalar
SET typ = (2 * ClosePrice + HighPrice + LowPrice + OpenPrice) / 5;
SET lol = MIND(LowPrice, 34);
SET hoh = MAXD(HighPrice, 34);

// xsa fonksiyonunun Matriks Explorer'da uygulanması
SET src1 = ((ClosePrice - MIND(LowPrice, 27)) / (MAXD(HighPrice, 27) - MIND(LowPrice, 27))) * 100;
SET xsa1 = (src1 + REF(src1, 1) + REF(src1, 2) + REF(src1, 3) + REF(src1, 4)) / 5;

SET src2 = ((ClosePrice - MIND(LowPrice, 27)) / (MAXD(HighPrice, 27) - MIND(LowPrice, 27))) * 100;
SET xsa2 = (xsa1 + REF(xsa1, 1) + REF(xsa1, 2)) / 3;

SET fundtrend = (3 * xsa1 - 2 * xsa2 - 50) * 1.032 + 50;

// EMA hesaplama
SET bullbearline = EMA((typ - lol) / (hoh - lol) * 100, 13);

// Banker Entry sinyali
SET bankerentry = CROSS(fundtrend, bullbearline) AND bullbearline < 25;

// Çizimler için kullanılacak değerler
DRAWICON(IF(bankerentry, 1, 0), ClosePrice, 6);
'İnsanların en hayırlısı insanlara en faydalı olanıdır'
(42 puan) tarafından
8,391 soru
8,345 cevap
4,713 yorum
18,037 kullanıcı