gb50k

For Lolikeet - 2 time frames 1 chart

script below
نص برمجي مفتوح المصدر

قام مؤلف هذا النص البرمجي بنشره وجعله مفتوح المصدر، بحيث يمكن للمتداولين فهمه والتحقق منه، وهو الأمر الذي يدخل ضمن قيم TradingView. تحياتنا للمؤلف! يمكنك استخدامه مجانًا، ولكن إعادة استخدام هذا الكود في منشور تحكمه قواعد الموقع. يمكنك جعله مفضلاً لاستخدامه على الرسم البياني.

إخلاء المسؤولية

لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.

هل تريد استخدام هذا النص البرمجي على الرسم البياني؟
//@version=2
study("My Script")
//plot(close)


res = input("240", type=resolution)
o = security(tickerid, res, open)
c = security(tickerid, res, close)
h = security(tickerid, res, high)
l = security(tickerid, res, low)


plotcandle(o, h, l, c, title='ceand', color = o < c ? green : red, wickcolor=black)
// most important for backtesting-
// if you use this code to add the 4hr time frame to a 1 hour chart....
// and you want to reference the last cadle in each time frame,
// its x[1]  for the 1hr and x[4] for the 4 hour.  you dont want to use the look at the last candle
// in the 4hr series it carries information that the 1 hr series doesnt have
// untill all 4 hours are done