Pine Script is a programming language developed by TradingView, used for writing proprietary indicators and strategies that can be added to your chart and used in technical analysis.
There is a special editor in the lower panel of your chart, specifically designed for writing and editing code. Additionally, this editor can function as an auto-highlighter, designed to highlight variables, functions, and tooltips. Essentially, it auto-highlights the built-in elements (variables and functions) of the language and sends hints in pop-up windows with additional information that appears when you hover over specific elements with your cursor.
The finished indicator can be added to the chart, saved for further use and editing, or published in our Community Scripts.
Basic reference materials:
We have created a simplified section where anyone can get acquainted with the structure of our language by using the simple script example that has been split up into individual parts for your convenience.
Another way to learn the language is through TradingView’s own built-in indicators that are written in Pine. The code for these indicators are open and readily accessible to anyone. Simply select your prefered indicator from the list and it will appear in the editor. Then experiment by making changes to the code.
In addition, you can find examples of other authors' work in our Community Scripts. An extensive number of them are open source scripts that are available to users.
Our Pine Script language is constantly developing and improving. We focus on feedback and try to expand the language to meet your needs. You can follow the updates on our release notes page, in the Tradingview chat or in the telegram channel, PineCoders Squawk Box.
If you cannot find what you are interested in within our reference materials, you can ask questions in the Tradingview chat where Pine Script is specifically discussed, or on the StackOverflow website, where we have a separate tag listed.