Library "string_extras" Additional String shortcuts, unshift and pop return the string ~without~ the first or last, so in use will still require to extract first or last character prior to overwriting a string with the output. can be imported "as str" to work side by side with regular pine last(_string) last char of a string Parameters: _string...
Library "HSupertrend" Supertrend implementation based on harmonic patterns hsupertrend(zProperties, pProperties, errorPercent, showPatterns, patternColor) derives supertrend based on harmonic patterns Parameters: zProperties : ZigzagProperties containing Zigzag length and source array pProperties : PatternProperties used for calculation ...
Library "ChasinAlts_Library" rci(_BCgtg, _Tgtg, _close, _smaLen, _bar_index) Parameters: _BCgtg _Tgtg _close _smaLen _bar_index printedBC(_time, _minPerc, _Tgtg, _lkbk) Parameters: _time _minPerc _Tgtg _lkbk form123(_ppLen, _BCgtg, _Tgtg, _high, _low, _close, _bar_index) Parameters: ...
Library "TrailingStops" This library contains functions to output trailing stop lines. f_marketStructureStop(_restartMode, _flipMode, _restartLowIn, _restartHighIn) Parameters: _restartMode - Defines how the stop lines persist. Allowed values are: "Always On" - The stop lines are always present and they just reset when they're crossed. ...
SignalBuilder Utility for building a collection of signal values. Provides a default view for displaying signals. Simplified API for aggregating signal values. Flexible for use with indicators and strategies. See the demo section for an example.
Library "MarketStructure" This library contains functions for identifying Lows and Highs in a rule-based way, and deriving useful information from them. f_simpleLowHigh() This function finds Local Lows and Highs, but NOT in order. A Local High is any candle that has its Low taken out on close by a subsequent candle (and vice-versa for Local Lows). The Local...
█ OVERVIEW This library is a Pine Script™ programmer’s tool for incorporating TradingView's well-known technical ratings within their scripts. The ratings produced by this library are the same as those from the speedometers in the technical analysis summary and the "Rating" indicator in the Screener , which use the aggregate biases of 26 technical...
Library "TurntLibrary" Collection of functions created for simplification/easy referencing. Includes variations of moving averages, length value oscillators, and a few other simple functions based upon HH/LL values. ma(source, length, type) Apply a moving average to a float value Parameters: source : Value to be used length : Number of bars to...
TableBuilder is a library designed to make it easier to create tables in PineScript. It allows you to more flexibly define the structure of a table before actually building it. Features: Style inheritance: styles are inherited from Table, to Column, to Row, and then Cell. Columns are useful for propagating/reusing style but they are not required. Add rows...
Utility for working with colors. Get the luminosity of a color and determine the optimal (black or white) foreground color.
Library "ISODateTime" getDateParts(dateStr) Get year, month, day from date string. Parameters: dateStr : : ISO 8601 format, i.e. "2022-05-04T14:00:00.001000-04:00" or "2022-05-04T14:00:00Z" Returns: array of int getTimeParts(dateStr) Get hour, minute, seconds from date string. Parameters: dateStr : : ISO 8601 format, i.e....
Library "Obj_XABCD_Harmonic" Harmonic XABCD Pattern object and associated methods. Easily validate, draw, and get information about harmonic patterns. See example code at the end of the script for details. init_params(pct_error, pct_asym, types, w_e, w_p, w_d) Create a harmonic parameters object (used by xabcd_harmonic object for pattern validation and...
This library contains functions that try to analyze trading signals performance. Like the % of average returns after a long or short signal is provided or the number of times that signal was correct, in the inmediate 2 candles after the signal.
Library "json" JSON Easy Object Create/stringiffy Functions to add/write JSON new (name , kind) -> object set (_item , _obj , _key ) -> key index for parent object's array add (_obj , _key , _item ) -> key index for parent object's array write (object , kind ) -> stringified object // (enter kind to cut off key...
█ OVERVIEW This is a simplest example of user-defined types (UDT) or objects , which simplify as alternative to hello world. █ CREDITS Tradingview █ USAGE These are the types used during initializations, commonly variables. export type Settings int bar float price string phrase ... Example of library function to print out label. ...
█ OVERVIEW This library is a Pine Script™ programmer’s tool containing custom user-defined types and functions to calculate Zig Zag indicators within their scripts. It is not a stand-alone indicator. Pine Script™ libraries are publications that contain reusable code for importing into Pine Script™ indicators, strategies, and other libraries. For more...
Library "FrizBug" Debug Tools | Pinescript Debugging Tool Kit All in one Debugger - the benefit of wrapper functions to simply wrap variables or outputs and have the code still execute the same. Perfect for Debugging on Pine str(inp) Overloaded tostring like Function for all type+including Object Variables will also do arrays and matricies of all...