Example function accepts loading of _value for types float, int, or string, then identifies whether the loaded _value is a string number, string, or number.
Library "json" Convert JSON strings to tradingview ▦ FEATURES ▦ █ Json to array █ Get json key names █ Get json key values █ Size of json get_json_keys_names(raw_json) Returns string array with all key names Parameters: raw_json : (string) Raw JSON string Returns: (string array) Array with all...
Library "CRCHud" Library of functions which will contain functions that allow reusable HUD (Heads up Display) components to used from within other scripts add_cell_change() - Adds a new cell to designated table which displays the data source value, the line color, data title, and automatically calculated %percent change stats based on lookback value...
Library "DiscordWebhookFunction" discordMarkdown(_str, _italic, _bold, _code, _strike, _under) Convert string to markdown formatting User can combine any function at the same time. Parameters: _str : String input _italic : Italic _bold : Bold _code : Code markdown _strike : Strikethrough _under : Underline Returns: string...
Library "MathComplexEvaluate" TODO: add library description here is_op(char) Check if char is a operator. Parameters: char : string, 1 character string. Returns: bool. operator(op, left, right) operation between left and right values. Parameters: op : string, operator string character. left : float, left value of operation. right : float,...
Library "FunctionDatestring" Methods to stringify date/time, altho there is already builtin support for it. datetime(unixtime) a stringified date stamp at specified unix time. Parameters: unixtime : int unix timestamp. Returns: string date_(unixtime) a stringified date stamp at specified unix time. Parameters: unixtime : int unix timestamp....
Custom toInteger() function accepts and truncates the following forms: const, input, simple, and series of the following types: float, integer, and string. Special thanks and credit to BeeHolder for idea on using str.format("{0}", string) as workaround for accepting and handling string types! NOTICE: This is an example script and not meant to be used as an...
Standard Array Functions Library by RagingRocketBull 2021 Version 1.0 This script provides a library of every standard Pinescript array function for live testing with all supported array types. You can find the full list of supported standard array functions below. There are several libraries: - Common String Functions Library - Common Array Functions Library ...
Common String Functions Library by RagingRocketBull 2021 Version 1.0 Pinescript now has strong support for arrays with many powerful functions, but still lacks built-in string functions. Luckily you can easily process and manipulate strings using arrays. This script provides a library of common string functions for everyday use, such as: indexOf, substr, replace,...
█ OVERVIEW This script provides string manipulation functions to help Pine coders. █ FUNCTIONS PROVIDED f_strLeft(_str, _n) Function returning the leftmost `_n` characters in `_str`. f_strRight(_str, _n) Function returning the rightmost `_n` characters in `_str`. f_strMid(_str, _from,...