OPEN-SOURCE SCRIPT

Pine Execution Map

Pine Script Execution Map

Overview:
This is an educational script for Pine Script developers. The script includes data structure, functions/methods, and process to capture and print Pine Script execution map of functions called while pine script execution.

Map of execution is produced for last/latest candle execution.

The script also has example code to call execution map methods and generate Pine Execution map.

Use cases:
  • Pine script developers can get view of how the functions are called
  • This can also be used while debugging the code and know which functions are called vs what developer expect code to do
  • One can use this while using any of the open source published script and understand how public script is organized and how functions of the script are called.



Code components:

User defined type


method called internally by other methods to generate level of function being executed


Method called from main/global scope to record execution of main scope code. There should be only one call to this method at the start of global scope.


Method called from main/global scope to record end of execution of main scope code. There should be only one call to this method at the end of global scope.


Method called from start of each function to record execution of function code


Method called from end of each function to record end of execution of function code


Pine code which generates execution map and show it as a label tooltip.


Snapshot 1:
This is the output of the script and can be viewed by hovering mouse pointer over the blue color diamond shaped label
스냅샷

Snapshot 2:
How to read the Pine execution map
스냅샷
educationalPine utilities

오픈 소스 스크립트

진정한 TradingView 정신에 따라, 이 스크립트의 저자는 트레이더들이 이해하고 검증할 수 있도록 오픈 소스로 공개했습니다. 저자에게 박수를 보냅니다! 이 코드는 무료로 사용할 수 있지만, 출판물에서 이 코드를 재사용하는 것은 하우스 룰에 의해 관리됩니다. 님은 즐겨찾기로 이 스크립트를 차트에서 쓸 수 있습니다.

차트에 이 스크립트를 사용하시겠습니까?

면책사항