답변완료
종목검색
1.아래는 검색하다 상한가 하한가 그리는 지표인데
종목검색지표로 좀 만들어 주세요
그리고 어디에 저장해서 사용하는 방법도 좀 알려주세요
종목검색 하는 방법 처음 사용자라서요
var : 하한가(0), DnLimit(0);
var : dn1(0), dn2(0), dn3(0), dn4(0), dn5(0),dn6(0),dn7(0);
var : 상한가(0), UpLimit(0);
var : up1(0), up2(0), up3(0), up4(0), up5(0),up6(0),Up7(0);
if date >= 19981207 then {
if date < 20050328 && CodeCategory() == 2 then
DnLimit = (BP * 0.12);
Else if date >= 20050328 and date < 20150615 Then
DnLimit = (BP * 0.15);
Else
DnLimit = (BP * 0.30);
if CodeCategory() == 2 then {
if date >= 20030721 then {
dn1 = int(DnLimit/100)*100;
dn2 = int(DnLimit/100)*100;
dn3 = int(DnLimit/100)*100;
dn4 = int(DnLimit/50)*50;
dn5 = int(DnLimit/10)*10;
dn6 = int(DnLimit/5)*5;
dn7 = int(DnLimit/1)*1;
}
else {
dn1 = int(DnLimit/1000)*1000;
dn2 = int(DnLimit/500)*500;
dn3 = int(DnLimit/100)*100;
dn4 = int(DnLimit/50)*50;
dn5 = int(DnLimit/10)*10;
dn6 = int(DnLimit/10)*10;
dn7 = int(DnLimit/1)*1;
}
}
Else {
dn1 = int(DnLimit/1000)*1000;
dn2 = int(DnLimit/500)*500;
dn3 = int(DnLimit/100)*100;
dn4 = int(DnLimit/50)*50;
dn5 = int(DnLimit/10)*10;
dn6 = int(DnLimit/5)*5;
dn7 = int(DnLimit/1)*1;
}
if CodeCategory() == 1 or CodeCategory() == 2 then {
if sdate < 20101004 Then{
If BP >= 500000 Then
하한가 = BP-dn1;
Else If BP >= 100000 Then
하한가 = BP-dn2;
Else If BP >= 50000 Then
하한가 = BP-dn3;
Else If BP >= 10000 Then
하한가 = BP-dn4;
Else If BP >= 5000 Then
하한가 = BP-dn5;
Else If BP >= 1000 Then
하한가 = BP-dn6;
Else
하한가 = BP-dn6;
}
else{
If BP >= 500000 Then
하한가 = BP-dn1;
Else If BP >= 100000 Then
하한가 = BP-dn2;
Else If BP >= 50000 Then
하한가 = BP-dn3;
Else If BP >= 10000 Then
하한가 = BP-dn4;
Else If BP >= 5000 Then
하한가 = BP-dn5;
Else If BP >= 1000 Then
하한가 = BP-dn6;
Else
하한가 = BP-dn7;
}
}
else if CodeCategory() == 8 or CodeCategory() == 9 then {
하한가 = BP-dn6;
}
}
if date >= 19981207 then {
if date < 20050328 && CodeCategory() == 2 then
UpLimit = (BP[0] * 1.12);
Else if date >= 20050328 and date < 20150615 Then
UpLimit = (BP[0] * 1.15);
Else
UpLimit = (BP[0] * 1.30);
if CodeCategory() == 2 then {
if date >= 20030721 then {
up1 = int(UpLimit/100+0.00001)*100;
up2 = int(UpLimit/100+0.00001)*100;
up3 = int(UpLimit/100+0.00001)*100;
up4 = int(UpLimit/50+0.00001)*50;
up5 = int(UpLimit/10+0.00001)*10;
up6 = int(UpLimit/5+0.00001)*5;
up7 = int(UpLimit/1+0.00001)*1;
}
else {
up1 = int(UpLimit/1000+0.00001)*1000;
up2 = int(UpLimit/500+0.00001)*500;
up3 = int(UpLimit/100+0.00001)*100;
up4 = int(UpLimit/50+0.00001)*50;
up5 = int(UpLimit/10+0.00001)*10;
up6 = int(UpLimit/10+0.00001)*10;
up7 = int(UpLimit/1+0.00001)*1;
}
}
Else {
up1 = int(UpLimit/1000+0.00001)*1000;
up2 = int(UpLimit/500+0.00001)*500;
up3 = int(UpLimit/100+0.00001)*100;
up4 = int(UpLimit/50+0.00001)*50;
up5 = int(UpLimit/10+0.00001)*10;
up6 = int(UpLimit/5+0.00001)*5;
up7 = int(UpLimit/1+0.00001)*1;
}
if CodeCategory() == 1 || CodeCategory() == 2 then {
if sdate < 20101004 Then{
If BP >= 500000 Then
상한가 = up1;
Else If BP >= 100000 Then
상한가 = iff(up2>=500000, up1, up2);
Else If BP >= 50000 Then
상한가 = iff(up3>=100000, up2, up3);
Else If BP >= 10000 Then
상한가 = iff(up4>=50000, up3, up4);
Else If BP >= 5000 Then
상한가 = iff(up5>=10000, up4, up5);
Else If BP >= 1000 Then
상한가 = iff(up5>=5000, up5, up6);
Else
상한가 = iff(up6>=1000, up6, up6);
}
Else{
If BP >= 500000 Then
상한가 = up1;
Else If BP >= 100000 Then
상한가 = iff(up2>=500000, up1, up2);
Else If BP >= 50000 Then
상한가 = iff(up3>=100000, up2, up3);
Else If BP >= 10000 Then
상한가 = iff(up4>=50000, up3, up4);
Else If BP >= 5000 Then
상한가 = iff(up5>=10000, up4, up5);
Else If BP >= 1000 Then
상한가 = iff(up5>=5000, up5, up6);
Else
상한가 = iff(up6>=1000, up6, up7);
}
}
else if CodeCategory() == 8 || CodeCategory() == 9 then { // ETF
상한가 = up6;
}
}
plot1(상한가);
plot2(하한가);
2.그럼 수고하세요
답변완료
지표문의
1.아래는 검색하다 상한가 하한가 그리는 지표인데
선물이나 해외선물 적용 할수 있도록 수정 안되나요 수정되면 범용지표로 좀 만들어 주세요
var : 하한가(0), DnLimit(0);
var : dn1(0), dn2(0), dn3(0), dn4(0), dn5(0),dn6(0),dn7(0);
var : 상한가(0), UpLimit(0);
var : up1(0), up2(0), up3(0), up4(0), up5(0),up6(0),Up7(0);
if date >= 19981207 then {
if date < 20050328 && CodeCategory() == 2 then
DnLimit = (BP * 0.12);
Else if date >= 20050328 and date < 20150615 Then
DnLimit = (BP * 0.15);
Else
DnLimit = (BP * 0.30);
if CodeCategory() == 2 then {
if date >= 20030721 then {
dn1 = int(DnLimit/100)*100;
dn2 = int(DnLimit/100)*100;
dn3 = int(DnLimit/100)*100;
dn4 = int(DnLimit/50)*50;
dn5 = int(DnLimit/10)*10;
dn6 = int(DnLimit/5)*5;
dn7 = int(DnLimit/1)*1;
}
else {
dn1 = int(DnLimit/1000)*1000;
dn2 = int(DnLimit/500)*500;
dn3 = int(DnLimit/100)*100;
dn4 = int(DnLimit/50)*50;
dn5 = int(DnLimit/10)*10;
dn6 = int(DnLimit/10)*10;
dn7 = int(DnLimit/1)*1;
}
}
Else {
dn1 = int(DnLimit/1000)*1000;
dn2 = int(DnLimit/500)*500;
dn3 = int(DnLimit/100)*100;
dn4 = int(DnLimit/50)*50;
dn5 = int(DnLimit/10)*10;
dn6 = int(DnLimit/5)*5;
dn7 = int(DnLimit/1)*1;
}
if CodeCategory() == 1 or CodeCategory() == 2 then {
if sdate < 20101004 Then{
If BP >= 500000 Then
하한가 = BP-dn1;
Else If BP >= 100000 Then
하한가 = BP-dn2;
Else If BP >= 50000 Then
하한가 = BP-dn3;
Else If BP >= 10000 Then
하한가 = BP-dn4;
Else If BP >= 5000 Then
하한가 = BP-dn5;
Else If BP >= 1000 Then
하한가 = BP-dn6;
Else
하한가 = BP-dn6;
}
else{
If BP >= 500000 Then
하한가 = BP-dn1;
Else If BP >= 100000 Then
하한가 = BP-dn2;
Else If BP >= 50000 Then
하한가 = BP-dn3;
Else If BP >= 10000 Then
하한가 = BP-dn4;
Else If BP >= 5000 Then
하한가 = BP-dn5;
Else If BP >= 1000 Then
하한가 = BP-dn6;
Else
하한가 = BP-dn7;
}
}
else if CodeCategory() == 8 or CodeCategory() == 9 then {
하한가 = BP-dn6;
}
}
if date >= 19981207 then {
if date < 20050328 && CodeCategory() == 2 then
UpLimit = (BP[0] * 1.12);
Else if date >= 20050328 and date < 20150615 Then
UpLimit = (BP[0] * 1.15);
Else
UpLimit = (BP[0] * 1.30);
if CodeCategory() == 2 then {
if date >= 20030721 then {
up1 = int(UpLimit/100+0.00001)*100;
up2 = int(UpLimit/100+0.00001)*100;
up3 = int(UpLimit/100+0.00001)*100;
up4 = int(UpLimit/50+0.00001)*50;
up5 = int(UpLimit/10+0.00001)*10;
up6 = int(UpLimit/5+0.00001)*5;
up7 = int(UpLimit/1+0.00001)*1;
}
else {
up1 = int(UpLimit/1000+0.00001)*1000;
up2 = int(UpLimit/500+0.00001)*500;
up3 = int(UpLimit/100+0.00001)*100;
up4 = int(UpLimit/50+0.00001)*50;
up5 = int(UpLimit/10+0.00001)*10;
up6 = int(UpLimit/10+0.00001)*10;
up7 = int(UpLimit/1+0.00001)*1;
}
}
Else {
up1 = int(UpLimit/1000+0.00001)*1000;
up2 = int(UpLimit/500+0.00001)*500;
up3 = int(UpLimit/100+0.00001)*100;
up4 = int(UpLimit/50+0.00001)*50;
up5 = int(UpLimit/10+0.00001)*10;
up6 = int(UpLimit/5+0.00001)*5;
up7 = int(UpLimit/1+0.00001)*1;
}
if CodeCategory() == 1 || CodeCategory() == 2 then {
if sdate < 20101004 Then{
If BP >= 500000 Then
상한가 = up1;
Else If BP >= 100000 Then
상한가 = iff(up2>=500000, up1, up2);
Else If BP >= 50000 Then
상한가 = iff(up3>=100000, up2, up3);
Else If BP >= 10000 Then
상한가 = iff(up4>=50000, up3, up4);
Else If BP >= 5000 Then
상한가 = iff(up5>=10000, up4, up5);
Else If BP >= 1000 Then
상한가 = iff(up5>=5000, up5, up6);
Else
상한가 = iff(up6>=1000, up6, up6);
}
Else{
If BP >= 500000 Then
상한가 = up1;
Else If BP >= 100000 Then
상한가 = iff(up2>=500000, up1, up2);
Else If BP >= 50000 Then
상한가 = iff(up3>=100000, up2, up3);
Else If BP >= 10000 Then
상한가 = iff(up4>=50000, up3, up4);
Else If BP >= 5000 Then
상한가 = iff(up5>=10000, up4, up5);
Else If BP >= 1000 Then
상한가 = iff(up5>=5000, up5, up6);
Else
상한가 = iff(up6>=1000, up6, up7);
}
}
else if CodeCategory() == 8 || CodeCategory() == 9 then { // ETF
상한가 = up6;
}
}
plot1(상한가);
plot2(하한가);
2.그럼 수고하세요
2025-10-15
103
글번호 194642
지표
답변완료
문의드립니다
수정부탁드립니다 그리고 설명도부탁드립니다
Inputs:
N(14), MA_Period(20), Smooth(3),
ThrBuy(70), ThrSell(55), Eps(1e-9),
AllowShort(1),
Qty(1); // 주문 수량
Vars:
ma(0), rsi(0), obv(0),
obvMin(0), obvMax(0), obvZ(0),
maMin(0), maMax(0), maZ(0),
combo(0), comboSm(0),
buySig(false), sellSig(false),
mp(0);
// --- 지표 계산 ---
ma = MA(Close, MA_Period);
rsi = RSI(N);
obv = OBV();
obvMin = Lowest(obv, N); obvMax = Highest(obv, N);
maMin = Lowest(ma, N); maMax = Highest(ma, N);
obvZ = 100 * (obv - obvMin) / Max(Eps, obvMax - obvMin);
maZ = 100 * (ma - maMin) / Max(Eps, maMax - maMin);
combo = (obvZ + rsi + maZ) / 3;
comboSm = MA(combo, Smooth);
// --- 트리거 ---
buySig = CrossUp(comboSm, ThrBuy);
sellSig = CrossDown(comboSm, ThrSell);
// --- 포지션 & 주문 ---
mp = MarketPosition();
If mp == 0 then begin
if buySig then Buy(Qty); // 롱 진입
if (AllowShort == 1) and sellSig then Short(Qty); // 숏 진입
end
else if mp == 1 then begin
if sellSig then Sell(Qty); // 롱 청산
end
else if mp == -1 then begin
if buySig then Cover(Qty); // 숏 청산
end;
답변완료
신호수식을 종목검색식으로 부탁드립니다
baseDis = (C/ avg(C, Per)) * 100;
rsiUp = avg(max(C -C(1), 0), rsiPer);
rsiDown = avg(max(c(1) - C, O), rsiPer);
rsiVal =100 - (100 / (1 + rsiUp / rsiDown));
rsiWeight = if(rsiVal <= 50,
0.5 + (rsiVal * 0.01),
0.5 + ((rsiVal - 50) * 0.03));
volAvg = avg(V, volPer);
volWeight = if(volAvg != 0, V / volAvg, 1.0);
rsiVolWeight = if(rsiVal < 30 and volWeight > 1.2, 0.8,
if(rsiVal > 70 and volWeight > 1.2, 1.3, 1.0));
weightedDis = baseDis * rsiWeight * volWeight * rsiVolWeight;
smoothedWeightedDis = avg(weightedDis, 3);
A=RSI(14);
조건=(smoothedWeightedDis(1)<=100 or
smoothedWeightedDis <= 100) &&
(a(1) <= 30 or a<= 30);
조건 && a>a(1)
지표변수
per 20
volper 20
rsiper 14
2025-10-14
101
글번호 194638
종목검색
답변완료
신호수식을 종목검색식으로 부탁드립니다
Hh= Highest(H, 40);
ll= Lowest(L, 40);
변동률조건= HH/LL*100 -100 <5;
H_전고점= Highest(H, 40),10;
라인=Valuewhen(1 ,변동률조건 ,HH);
crossup(c,라인) && 변동률조건(1) &&
라인 < H_전고점
2025-10-14
138
글번호 194637
종목검색