• Produk
  • Komunitas
  • Pasar
  • Broker
  • Lebih lanjut
Mulai
  • Komunitas
  • /Indikator dan strategi
  • /Developers

Developers

Multi-Timeframe Configuration DemoThis is a developer friendly solution to the current PineScript limitation of not being able to easily configure presets for multiple timeframes. If you're developing multi-timeframe strategies then you've no doubt done battle with built-in `input` function which only allows for a single default value. You've probably come up with all kinds of fancy workarounds, including messy hardcoding, and even gritting your teeth and patiently reentering all the necessary values each time you refresh the chart or change the timeframe. The last one is my personal favourite. As you can see in the code below we have defined a `usePresets` condition which tells the script to use our preset configuration, otherwise the default `input` values will be used. If `usePresets` is false then we use our presets which are defined in a (fairly) easy to read condition chain with the help of some basic timeframe utility functions. Obviously this is nothing groundbreaking, but its helped me clean up my scripts a bit, so hopefully it will help you too.
Indikator Pine Script®
oleh sourcey
11

Pilih data pasar yang disediakan oleh ICE Data Services. Pilih data referensi yang disediakan oleh FactSet. Copyright © 2025 FactSet Research Systems Inc.© 2025 TradingView, Inc.

Lebih dari sekadar produk
  • Superchart
Penyaring
  • Saham
  • ETF
  • Obligasi
  • Koin crypto
  • Pasangan CEX
  • Pasangan DEX
  • Pine
Heatmap
  • Saham
  • ETF
  • Crypto
Kalender
  • Ekonomis
  • Perolehan
  • Dividen
Produk lainnya
  • Kurva Imbal Hasil
  • Options
  • Aliran berita
  • Skrip Pine®
Aplikasi
  • Mobile
  • Desktop
Komunitas
  • Jejaring sosial
  • Tembok Cinta
  • Refer teman
  • Tata Tertib
  • Moderator
Ide-Ide
  • Trading
  • Edukasi
  • Pilihan editor
Skrip Pine
  • Indikator & strategi
  • Wizard
  • Freelancer
Peralatan & langganan
  • Fitur-fitur
  • Harga Akun
  • Data pasar
Trading
  • Ikhtisar
  • Broker
Penawaran spesial
  • Kontrak berjangka CME Group
  • Kontrak berjangka Eurex
  • Bundel saham AS
Tentang perusahaan
  • Tentang kami
  • Misi luar angksa
  • Blog
  • Karir
  • Media kit
Merchandise
  • Toko TradingView
  • Kartu tarot untuk trader
  • C63 TradeTime
Kebijakan & keamanan
  • Syarat penggunaan
  • Pernyataan Penyangkalan
  • Kebijakan Privasi
  • Kebijakan Cookie
  • Pernyataan Aksesibilitas
  • Tips keamanan
  • Program Pencari Bug
  • Halaman status
Solusi bisnis
  • Widget
  • Perpustakaan charting
  • Lightweight Charts™
  • Advanced Chart
  • Platform Trading
Peluang pertumbuhan
  • Periklanan
  • Integrasi broker
  • Program partner
  • Program Edukasi
Komunitas
  • Jejaring sosial
  • Tembok Cinta
  • Refer teman
  • Tata Tertib
  • Moderator
Ide-Ide
  • Trading
  • Edukasi
  • Pilihan editor
Skrip Pine
  • Indikator & strategi
  • Wizard
  • Freelancer
Solusi bisnis
  • Widget
  • Perpustakaan charting
  • Lightweight Charts™
  • Advanced Chart
  • Platform Trading
Peluang pertumbuhan
  • Periklanan
  • Integrasi broker
  • Program partner
  • Program Edukasi
Look FirstLook First