ToClrToStrContains functions for conversion of color to string and vice versa:
method toClr( string this ) - converts string reperesentation of color (in hex format) to color
method toHex( color this ) - converts color to string (hex form)
method toRgb( color this ) - converts color to string ("rgb(11,11,11,0)" form)
Thanks to @ImmortalFreedom for his `color_tostring()` function from "RGB Color Fiddler"
Indicators and strategies
Time Zone CorrectorThe Time Zone Corrector library provides a utility function designed to adjust time based on the user's current time zone. This library supports a wide range of time zones across the Americas, Europe, Asia, and Oceania, making it highly versatile for traders around the world. It simulates a switch-case structure using ternary operators to output the appropriate time offset relative to UTC.
Whether you're dealing with market sessions in New York, Tokyo, London, or other major trading hubs, this library helps ensure your trading algorithms can accurately account for time differences. The library is particularly useful for strategies that rely on precise timing, as it dynamically adjusts the time zone offset depending on the symbol being traded.
SessionLibrary "Session"
Helper functions for trading sessions. TradingView doesn't provide correct data when
calling some of the convenience methods like session.ismarket when you are looking at futures charts. This library corrects those mistakes by providing functions with the same names as the TradingView default properties. that reference a custom defined set of session hours for futures. It also provides a way for consumers to customize the map values by calling getSessionMap() and then overwriting (or adding) custom session definitions.
getSessionMap()
Returns a map of the futures rth & eth session hours. The map is keyed with symbol:session format (eg. ES:market or ES:overnight).
Returns: A map of futures symbols and their associated session hours.
getSessionString(session, symbol, sessionMap)
Returns a session string representing the session hours (and days) for the requested symbol (or the chart's symbol if the symbol value is not provided). If the session string is not found in the collection, it will return a blank string.
Parameters:
session (string) : A string representing the session hour being requested. One of: market (regular trading hours), overnight (extended/electronic trading hours), postmarket (after-hours), premarket
symbol (string) : The symbol to check. Optional. Defaults to chart symbol.
sessionMap (map) : The map of futures session hours. Optional. Uses default if not provided.
inSession(session, sessionMap, barsBack)
Returns true if the current symbol is currently in the session parameters defined by sessionString.
Parameters:
session (string) : A string representing the session hour being requested. One of: market (regular trading hours), overnight (extended/electronic trading hours), postmarket (after-hours), premarket
sessionMap (map) : The map of futures session hours. Optional. Uses default if not provided.
barsBack (int) : Private. Only used by futures to check islastbar. Optional. The default is 0.
ismarket(sessionMap)
Returns true if the current bar is a part of the regular trading hours (i.e. market hours), false otherwise. Works for futures (TradingView's methods do not).
Parameters:
sessionMap (map) : The map of futures session hours. Optional. Uses default if not provided.
Returns: bool
isfirstbar()
Returns true if the current bar is the first bar of the day's session, false otherwise. If extended session information is used, only returns true on the first bar of the pre-market bars. Works for futures (TradingView's methods do not).
Returns: bool
islastbar()
Returns true if the current bar is the last bar of the day's session, false otherwise. If extended session information is used, only returns true on the last bar of the post-market bars. Works for futures (TradingView's methods do not).
Returns: bool
ispremarket(sessionMap)
Returns true if the current bar is a part of the pre-market, false otherwise. On non-intraday charts always returns false. Works for futures (TradingView's methods do not).
Parameters:
sessionMap (map) : The map of futures session hours. Optional. Uses default if not provided.
Returns: bool
ispostmarket(sessionMap)
Returns true if the current bar is a part of the post-market, false otherwise. On non-intraday charts always returns false. Works for futures (TradingView's methods do not).
Parameters:
sessionMap (map) : The map of futures session hours. Optional. Uses default if not provided.
Returns: bool
isfirstbar_regular(sessionMap)
Returns true on the first regular session bar of the day, false otherwise. The result is the same whether extended session information is used or not. Works for futures (TradingView's methods do not).
Parameters:
sessionMap (map) : The map of futures session hours. Optional. Uses default if not provided.
Returns: bool
islastbar_regular(sessionMap)
Returns true on the last regular session bar of the day, false otherwise. The result is the same whether extended session information is used or not. Works for futures (TradingView's methods do not).
Parameters:
sessionMap (map) : The map of futures session hours. Optional. Uses default if not provided.
Returns: bool
isovernight(sessionMap)
Returns true if the current bar is a part of the pre-market or post-market, false otherwise. On non-intraday charts always returns false.
Parameters:
sessionMap (map) : The map of futures session hours. Optional. Uses default if not provided.
Returns: bool
getSessionHighAndLow(session, sessionMap)
Returns a tuple containing the high and low print during the specified session.
Parameters:
session (string) : The session for which to get the high & low prints. Defaults to market.
sessionMap (map) : The map of futures session hours. Optional. Uses default if not provided.
Returns: A tuple containing
TradingHook_LibraryLibrary "TradingHook_Library"
This library is a client script for making a webhook signal formatted string to TradingHook webhook server.
buy_message(password, amount, order_name)
Make a buy Message for TradingHook.
Parameters:
password (string) : (string) password that you set in .env file.
amount (float) : (float) amount. If not set, your strategy qty will be sent.
order_name (string) : (string) order_name. The default name is "Order".
Returns: (string) A string containing the formatted webhook message.
sell_message(password, percent, order_name)
Make a sell message for TradingHook.
Parameters:
password (string) : (string) password that you set in .env file.
percent (string) : (string) what percentage of your quantity you want to sell.
order_name (string) : (string) order_name. The default name is "Order".
Returns: (string) A string containing the formatted webhook message.
entry_message(password, amount, leverage, order_name)
Make a Entry Message for TradingHook.
Parameters:
password (string) : (string) password that you set in .env file.
amount (float) : (float) amount. If not set, your strategy qty will be sent.
leverage (int) : (int) leverage. If not set, your leverage doesn't change.
order_name (string) : (string) order_name. The default name is "Order".
Returns: (string) A string containing the formatted webhook message.
close_message(password, percent, amount, order_name)
Make a close message for TradingHook.
Parameters:
password (string) : (string) password that you set in .env file.
percent (string) : (string) what percentage of your quantity you want to close.
amount (float) : (float) quantity you want to close.
order_name (string) : (string) order_name. The default name is "Order".
Returns: (string) A string containing the formatted webhook message.
iteratorThe "Iterator" library is designed to provide a flexible way to work with sequences of values. This library offers a set of functions to create and manage iterators for various data types, including integers, floats, and more. Whether you need to generate an array of values with specific increments or iterate over elements in reverse order, this library has you covered.
Key Features:
Array Creation: Easily generate arrays of integers or floats with customizable steps, both inclusive and exclusive of the end values.
Flexible Iteration: Includes methods to iterate over arrays of different types, such as booleans, integers, floats, strings, colors, and drawing objects like lines and labels.
Reverse Iteration: Support for reverse iteration, giving you control over the order in which elements are processed.
Automatic Loop Control: One of the key advantages of this library is that when using the .iterate() method, it only loops over the array when there are values present. This means you don’t have to manually check if the array is populated before iterating, simplifying your code and reducing potential errors.
Versatile Use Cases: Ideal for scenarios where you need to loop over an array without worrying about empty arrays or checking conditions manually.
This library is particularly useful in cases where you need to perform operations on each element in an array, ensuring that your loops are efficient and free from unnecessary checks.
Library "iterator"
The "iterator" library provides a versatile and efficient set of functions for creating and managing iterators.
It allows you to generate arrays of integers or floats with customizable steps, both inclusive and exclusive of the end values.
The library also includes methods for iterating over various types, including booleans, integers, floats, strings, colors,
and drawing objects like lines and labels. With support for reverse iteration and flexible customization options.
iterator(stop, start, step)
Creates an array of integers from start to stop with a specified step, excluding the stop value.
Parameters:
stop (int) : The end value of the iterator, exclusive.
start (int) : The starting value of the iterator. Default is 0.
step (int) : The increment value for each step in the iterator. Default is 1. Must be greater than 0.
Returns: An array of integers incremented by the step value from start to stop. Will return and empty array if start = stop.
iterator(stop, start, step)
Creates an array of floats from start to stop with a specified step, excluding the stop value.
Parameters:
stop (float) : The end value of the iterator, exclusive.
start (float) : The starting value of the iterator. Default is 0.
step (float) : The increment value for each step in the iterator. Default is 1. Must be greater than 0.
Returns: An array of floats incremented by the step value from start to stop. Will return and empty array if start = stop.
iterator_inclusive(stop, start, step)
Creates an array of integers from start to stop with a specified step, including the stop value.
Parameters:
stop (int) : The end value of the iterator, inclusive.
start (int) : The starting value of the iterator. Default is 0.
step (int) : The increment value for each step in the iterator. Default is 1. Must be greater than 0.
Returns: An array of integers incremented by the step value from start to stop, including the stop value.
iterator_inclusive(stop, start, step)
Creates an array of floats from start to stop with a specified step, including the stop value.
Parameters:
stop (float) : The end value of the iterator, inclusive.
start (float) : The starting value of the iterator. Default is 0.
step (float) : The increment value for each step in the iterator. Default is 1. Must be greater than 0.
Returns: An array of floats incremented by the step value from start to stop, including the stop value.
itr(stop, start, step)
Creates an array of integers from start to stop with a specified step, excluding the stop value.
Parameters:
stop (int) : The end value of the iterator, exclusive.
start (int) : The starting value of the iterator. Default is 0.
step (int) : The increment value for each step in the iterator. Default is 1. Must be greater than 0.
Returns: An array of integers incremented by the step value from start to stop.
itr(stop, start, step)
Creates an array of floats from start to stop with a specified step, excluding the stop value.
Parameters:
stop (float) : The end value of the iterator, exclusive.
start (float) : The starting value of the iterator. Default is 0.
step (float) : The increment value for each step in the iterator. Default is 1. Must be greater than 0.
Returns: An array of floats incremented by the step value from start to stop.
itr_in(stop, start, step)
Creates an array of integers from start to stop with a specified step, including the stop value.
Parameters:
stop (int) : The end value of the iterator, inclusive.
start (int) : The starting value of the iterator. Default is 0.
step (int) : The increment value for each step in the iterator. Default is 1. Must be greater than 0.
Returns: An array of integers incremented by the step value from start to stop, including the stop value.
itr_in(stop, start, step)
Creates an array of floats from start to stop with a specified step, including the stop value.
Parameters:
stop (float) : The end value of the iterator, inclusive.
start (float) : The starting value of the iterator. Default is 0.
step (float) : The increment value for each step in the iterator. Default is 1. Must be greater than 0.
Returns: An array of floats incremented by the step value from start to stop, including the stop value.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
method iterate(self, reverse)
Creates an iterator array for the indices of ana array, with an option to reverse the order.
Namespace types: array
Parameters:
self (array) : The array to iterate over.
reverse (bool) : A boolean flag indicating whether to reverse the iterator order. Default is false.
Returns: An array of integers representing the indices of the array. The order can be reversed if specified.
whookLibrary "whook"
This library provides functions for generating trading alerts for `whook`
check this -> github.com
Currently supported exchanges:
Kucoin futures
Bitget futures
Coinex futures
Bingx
OKX futures ( also its demo mode )
Bybit futures ( also Bybit testnet )
Binance futures ( also Binance futures testnet )
Phemex futures ( also Phemex testnet )
Kraken futures ( also Kraken futures testnet )
# --- Test Cases ---
Note: These test cases are for demonstration purposes only and may not cover all scenarios.
// buy(string account, float amount, string unit = "units", float leverage = 1)
buy("MyAccount", 100, "units", 1)
buy("MyAccount", 1000, "USDT", 5)
buy("MyAccount", 50, "percent", 2)
// sell(string account, float amount, string unit = "units", float leverage = 1)
sell("MyAccount", 50, "units", 1)
sell("MyAccount", 500, "USDT", 3)
sell("MyAccount", 25, "percent", 2)
// set_position(string account, float amount, string unit = "units", float leverage = 1)
set_position("MyAccount", 100, "units", 1)
set_position("MyAccount", 1000, "USDT", 5)
set_position("MyAccount", 50, "percent", 2)
// limit_buy(string account, float amount, float price, string unit = "units", float leverage = 1, string id = "")
limit_buy("MyAccount", 100, 10000, "units", 1, "MyBuyOrder")
limit_buy("MyAccount", 1000, 10500, "USDT", 5)
limit_buy("MyAccount", 50, 11000, "percent", 2)
// limit_sell(string account, float amount, float price, string unit = "units", float leverage = 1, string id = "")
limit_sell("MyAccount", 50, 10000, "units", 1, "MySellOrder")
limit_sell("MyAccount", 500, 9500, "USDT", 3)
limit_sell("MyAccount", 25, 9000, "percent", 2)
// close_percent(string account, float pct = 100)
close_percent("MyAccount", 100)
close_percent("MyAccount", 50)
buy(account, amount, unit, leverage)
Sends a trading alert to execute a market buy order.
Parameters:
account (string) : The account ID.
amount (float) : The amount to buy (can be in USD, units, or percentage).
unit (string) : The unit of the amount (optional, defaults to "units").
leverage (float) : The leverage to use (optional, defaults to 1x).
sell(account, amount, unit, leverage)
Sends a trading alert to execute a market sell order.
Parameters:
account (string) : The account ID.
amount (float) : The amount to sell (can be in USD, units, or percentage).
unit (string) : The unit of the amount (optional, defaults to "units").
leverage (float) : The leverage to use (optional, defaults to 1x).
set_position(account, amount, unit, leverage)
Sends a trading alert to set a position.
Parameters:
account (string) : The account ID.
amount (float) : The amount to set the position to (can be in USD, units, or percentage).
unit (string) : The unit of the amount (optional, defaults to "units").
leverage (float) : The leverage to use (optional, defaults to 1x).
limit_buy(account, amount, price, unit, leverage, id)
Sends a trading alert to place a limit buy order.
Parameters:
account (string) : The account ID.
amount (float) : The amount to buy (can be in USD, units, or percentage).
price (float) : The limit price.
unit (string) : The unit of the amount (optional, defaults to "units").
leverage (float) : The leverage to use (optional, defaults to 1x).
id (string) : An optional custom ID for the limit order.
limit_sell(account, amount, price, unit, leverage, id)
Sends a trading alert to place a limit sell order.
Parameters:
account (string) : The account ID.
amount (float) : The amount to sell (can be in USD, units, or percentage).
price (float) : The limit price.
unit (string) : The unit of the amount (optional, defaults to "units").
leverage (float) : The leverage to use (optional, defaults to 1x).
id (string) : An optional custom ID for the limit order.
close_percent(account, pct)
Sends an alert to close a position on Phemex.
Parameters:
account (string) : The account ID.
pct (float) : The percentage of the position to close (optional, defaults to 100%).
csv_series_libraryThe CSV Series Library is an innovative tool designed for Pine Script developers to efficiently parse and handle CSV data for series generation. This library seamlessly integrates with TradingView, enabling the storage and manipulation of large CSV datasets across multiple Pine Script libraries. It's optimized for performance and scalability, ensuring smooth operation even with extensive data.
Features:
Multi-library Support: Allows for distribution of large CSV datasets across several libraries, ensuring efficient data management and retrieval.
Dynamic CSV Parsing: Provides robust Python scripts for reading, formatting, and partitioning CSV data, tailored specifically for Pine Script requirements.
Extensive Data Handling: Supports parsing CSV strings into Pine Script-readable series, facilitating complex financial data analysis.
Automated Function Generation: Automatically wraps CSV blocks into distinct Pine Script functions, streamlining the process of integrating CSV data into Pine Script logic.
Usage:
Ideal for traders and developers who require extensive data analysis capabilities within Pine Script, especially when dealing with large datasets that need to be partitioned into manageable blocks. The library includes a set of predefined functions for parsing CSV data into usable series, making it indispensable for advanced trading strategy development.
Example Implementation:
CSV data is transformed into Pine Script series using generated functions.
Multiple CSV blocks can be managed and parsed, allowing for flexible data series creation.
The library includes comprehensive examples demonstrating the conversion of standard CSV files into functional Pine Script code.
To effectively utilize the CSV Series Library in Pine Script, it is imperative to initially generate the correct data format using the accompanying Python program. Here is a detailed explanation of the necessary steps:
1. Preparing the CSV Data:
The Python script provided with the CSV Series Library is designed to handle CSV files that strictly contain no-space, comma-separated single values. It is crucial that your CSV file adheres to this format to ensure compatibility and correctness of the data processing.
2. Using the Python Program to Generate Data:
Once your CSV file is prepared, you need to use the Python program to convert this file into a format that Pine Script can interpret. The Python script performs several key functions:
Reads the CSV file, ensuring that it matches the required format of no-space, comma-separated values.
Formats the data into blocks, where each block is a string of data that does not exceed a specified character limit (default is 4,000 characters). This helps manage large datasets by breaking them down into manageable chunks.
Wraps these blocks into Pine Script functions, each block being encapsulated in its own function to maintain organization and ease of access.
3. Generating and Managing Multiple Libraries:
If the data from your CSV file exceeds the Pine Script or platform limits (e.g., too many characters for a single script), the Python script can split this data into multiple blocks across several files.
4. Creating a Pine Script Library:
After generating the formatted data blocks, you must create a Pine Script library where these blocks are integrated. Each block of data is contained within its function, like my_csv_0(), my_csv_1(), etc. The full_csv() function in Pine Script then dynamically loads and concatenates these blocks to reconstruct the full data series.
5. Exporting the full_csv() Function:
Once your Pine Script library is set up with all the CSV data blocks and the full_csv() function, you export this function from the library. This exported function can then be used in your actual trading projects. It allows Pine Script to access and utilize the entire dataset as if it were a single, continuous series, despite potentially being segmented across multiple library files.
6. Reconstructing the Full Series Using vec :
When your dataset is particularly large, necessitating division into multiple parts, the vec type is instrumental in managing this complexity. Here’s how you can effectively reconstruct and utilize your segmented data:
Definition of vec Type: The vec type in Pine Script is specifically designed to hold a dataset as an array of floats, allowing you to manage chunks of CSV data efficiently.
Creating an Array of vec Instances: Once you have your data split into multiple blocks and each block is wrapped into its own function within Pine Script libraries, you will need to construct an array of vec instances. Each instance corresponds to a segment of your complete dataset.
Using array.from(): To create this array, you utilize the array.from() function in Pine Script. This function takes multiple arguments, each being a vec instance that encapsulates a data block. Here’s a generic example:
vec series_vector = array.from(vec.new(data_block_1), vec.new(data_block_2), ..., vec.new(data_block_n))
In this example, data_block_1, data_block_2, ..., data_block_n represent the different segments of your dataset, each returned from their respective functions like my_csv_0(), my_csv_1(), etc.
Accessing and Utilizing the Data: Once you have your vec array set up, you can access and manipulate the full series through Pine Script functions designed to handle such structures. You can traverse through each vec instance, processing or analyzing the data as required by your trading strategy.
This approach allows Pine Script users to handle very large datasets that exceed single-script limits by segmenting them and then methodically reconstructing the dataset for comprehensive analysis. The vec structure ensures that even with segmentation, the data can be accessed and utilized as if it were contiguous, thus enabling powerful and flexible data manipulation within Pine Script.
Library "csv_series_library"
A library for parsing and handling CSV data to generate series in Pine Script. Generally you will store the csv strings generated from the python code in libraries. It is set up so you can have multiple libraries to store large chunks of data. Just export the full_csv() function for use with this library.
method csv_parse(data)
Namespace types: array
Parameters:
data (array)
method make_series(series_container, start_index)
Namespace types: array
Parameters:
series_container (array)
start_index (int)
Returns: A tuple containing the current value of the series and a boolean indicating if the data is valid.
method make_series(series_vector, start_index)
Namespace types: array
Parameters:
series_vector (array)
start_index (int)
Returns: A tuple containing the current value of the series and a boolean indicating if the data is valid.
vec
A type that holds a dataset as an array of float arrays.
Fields:
data_set (array) : A chunk of csv data. (A float array)
DynamicRSILibrary "DynamicRSI"
The "DynamicRSI" library provides a method to calculate a Dynamic Relative Strength Index (RSI) that adjusts its sensitivity based on market volatility. By combining short and long RSI periods with a weighted average influenced by the market's volatility, this library allows users to obtain a more responsive RSI tailored to changing market conditions.
"DynamicRSI" 라이브러리는 시장 변동성에 따라 감도를 조정하는 동적 상대 강도 지수(RSI)를 계산하는 방법을 제공합니다. 짧은 RSI와 긴 RSI 기간을 시장 변동성에 따라 가중 평균하여 결합함으로써, 이 라이브러리는 시장 상황에 맞게 보다 유연하게 반응하는 RSI를 제공합니다.
Function: drsi(src, minLength, maxLength, volatilityPeriod)
함수: drsi(src, minLength, maxLength, volatilityPeriod)
Parameters:
src (float)
The source data to calculate the RSI (e.g., close price). This is the price data that the RSI is calculated on.
RSI를 계산하기 위한 입력 데이터입니다(예: 종가(close) ). 이 값은 RSI를 계산하는 기준이 되는 가격 데이터입니다.
minLength (simple int)
The period for the shorter RSI. This parameter controls the sensitivity of the RSI, with a shorter period making the RSI more reactive to price changes.
짧은 RSI 기간입니다. 이 매개변수는 RSI의 감도를 제어하며, 더 짧은 기간은 RSI가 가격 변화에 더 민감하게 반응하게 합니다.
maxLength (simple int)
The period for the longer RSI. This parameter provides a smoother RSI, which is less sensitive to short-term price fluctuations.
긴 RSI 기간입니다. 이 매개변수는 더 부드러운 RSI를 제공하며, 단기적인 가격 변동에 덜 민감하게 반응합니다.
volatilityPeriod (simple int)
The period used for calculating the Average True Range (ATR) to measure market volatility. This volatility is then used to adjust the weighting between the short and long RSI, making the final Dynamic RSI more adaptive to market conditions.
시장 변동성을 측정하기 위해 평균 진정 범위(ATR)를 계산하는 기간입니다. 이 변동성을 기반으로 짧은 RSI와 긴 RSI 간의 가중치를 조정하여 최종 Dynamic RSI가 시장 상황에 더 잘 적응할 수 있도록 합니다.
Description:
The drsi function calculates a Dynamic RSI by weighting the short-term and long-term RSI values according to the current market volatility. The function uses the ATR to determine the market's volatility, applying more weight to the short-term RSI when volatility is high and more weight to the long-term RSI when volatility is low. This approach ensures that the RSI is more responsive during volatile periods and smoother during stable periods, providing traders with a more effective tool for identifying overbought and oversold conditions in varying market environments.
drsi 함수는 현재 시장 변동성에 따라 단기와 장기의 RSI 값을 가중치로 조정하여 Dynamic RSI를 계산합니다. 이 함수는 시장의 변동성을 판단하기 위해 ATR을 사용하며, 변동성이 높을 때는 단기 RSI에 더 많은 가중치를 적용하고, 변동성이 낮을 때는 장기 RSI에 더 많은 가중치를 적용합니다. 이 접근 방식은 변동성이 큰 기간 동안 RSI가 더 민감하게 반응하고, 안정적인 기간 동안 더 부드럽게 반응하도록 하여, 다양한 시장 환경에서 과매수 및 과매도 상태를 식별하는 데 보다 효과적인 도구를 제공합니다.
LibraryBitwiseOperandsLibrary "LibraryBitwiseOperands"
Description: When you need more space for your data you can use bitwise operations. For example if you are creating an Order Block indicator and you have multiple types then you can define variables for each type with only one bit set like these:
const int TYPE_OB = 1
const int TYPE_HH = 2
const int TYPE_LH = 4
const int TYPE_HL = 8
const int TYPE_LL = 16
const int TYPE_BOS = 32
const int TYPE_CHOCH = 64
bitwise_shift_left(x, y)
bitwise_shift_left(): Bitwise left shift: x << y
Parameters:
x (int)
y (int)
Returns: : The left operand’s value is moved toward left by the number of bits specified by the right operand.
bitwise_shift_right(x, y)
bitwise_shift_right(): Bitwise right shift: x >> y
Parameters:
x (int)
y (int)
Returns: : The left operand’s value is moved toward right by the number of bits specified by the right operand.
bitwise_not(x)
bitwise_not(): Bitwise NOT: ~x
Parameters:
x (int)
Returns: : Inverts individual bits.
bitwise_and(x, y)
bitwise_and(): Bitwise AND: x & y
Parameters:
x (int)
y (int)
Returns: : Result bit 1, if both operand bits are 1; otherwise results bit 0.
bitwise_or(x, y)
bitwise_or(): Bitwise OR: x | y
Parameters:
x (int)
y (int)
Returns: : Result bit 1, if any of the operand bit is 1; otherwise results bit 0.
bitwise_xor(x, y)
bitwise_xor(): Bitwise (exclusive OR) XOR: x ^ y
Parameters:
x (int)
y (int)
Returns: : Result bit 1, if any of the operand bit is 1 but not both, otherwise results bit 0.
logical_xor(x, y)
logical_xor(): Logical (exclusive OR) XOR: x xor y
Parameters:
x (bool)
y (bool)
Returns: : Result true, if any of the operand bit are different, otherwise results bit 0.
bit_check(x, y)
bit_check(): Bitwise Checks the specified bit
Parameters:
x (int)
y (int)
Returns: : Returns True if the bit is set.
bit_set(x, y)
bit_set(): Bitwise Sets the specified bit
Parameters:
x (int)
y (int)
Returns: : Returns a value with the bit set.
bit_clear(x, y)
bit_clear(): Bitwise Clears the specified bit
Parameters:
x (int)
y (int)
Returns: : Returns a value with the bit cleared.
bit_flip(x, y)
bit_flip(): Bitwise Inverts the specified bit
Parameters:
x (int)
y (int)
Returns: : Returns a value with the bit inverted.
bitmask_check(x, mask)
bitmask_check(): Bitwise Checks the specified Mask
Parameters:
x (int)
mask (int)
Returns: : Returns True if the mask is set.
bitmask_set(x, mask)
bitmask_set(): Bitwise Sets the specified Mask
Parameters:
x (int)
mask (int)
Returns: : Returns a value with the mask set.
bitmask_clear(x, mask)
bitmask_clear(): Bitwise Clears the specified Mask
Parameters:
x (int)
mask (int)
Returns: : Returns a value with the mask cleared.
bitmask_flip(x, mask)
bitmask_flip(): Inverts the specified Mask
Parameters:
x (int)
mask (int)
Returns: : Returns a value with the mask inverted.
math_bit_check(x, y)
math_bit_check(): Fast arithmetic bitwise Checks the specified Mask
Parameters:
x (int)
y (int)
Returns: : Returns True if the mask is set.
math_bit_set(x, y)
math_bit_set(): Fast arithmetic bitwise Sets the specified bit
Parameters:
x (int)
y (int)
Returns: : Returns a value with the bit set.
math_bit_clear(x, y)
math_bit_clear(): Fast arithmetic bitwise Clears the specified bit
Parameters:
x (int)
y (int)
Returns: : Returns a value with the bit cleared.
math_bitmask_check(x, y)
math_bitmask_check(): Fast arithmetic bitwise Checks the specified Mask
Parameters:
x (int)
y (int)
Returns: : Returns True if the mask is set.
math_bitmask_set(x, y)
math_bitmask_set(): Fast arithmetic bitwise Sets the specified Mask
Parameters:
x (int)
y (int)
Returns: : Returns a value with the mask set.
math_bitmask_clear(x, y)
math_bitmask_clear(): Fast arithmetic bitwise Clears the specified Mask
Parameters:
x (int)
y (int)
Returns: : Returns a value with the mask cleared.
Order Block Overlapping Drawing [TradingFinder]🔵 Introduction
Technical analysis is a fundamental tool in financial markets, helping traders identify key areas on price charts to make informed trading decisions. The ICT (Inner Circle Trader) style, developed by Michael Huddleston, is one of the most advanced methods in this field.
It enables traders to precisely identify and exploit critical zones such as Order Blocks, Breaker Blocks, Fair Value Gaps (FVGs), and Inversion Fair Value Gaps (IFVGs).
To streamline and simplify the use of these key areas, a library has been developed in Pine Script, the scripting language for the TradingView platform. This library allows you to automatically detect overlapping zones between Order Blocks and other similar areas, and visually display them on your chart.
This tool is particularly useful for creating indicators like Balanced Price Range (BPR) and ICT Unicorn Model.
🔵 How to Use
This section explains how to use the Pine Script library. This library assists you in easily identifying and analyzing overlapping areas between Order Blocks and other zones, such as Breaker Blocks and Fair Value Gaps.
To add "Order Block Overlapping Drawing", you must first add the following code to your script.
import TFlab/OrderBlockOverlappingDrawing/1
🟣 Inputs
The library includes the "OBOverlappingDrawing" function, which you can use to detect and display overlapping zones. This function identifies and draws overlapping zones based on the Order Block type, trigger conditions, previous and current prices, and other relevant parameters.
🟣 Parameters
OBOverlappingDrawing(OBType , TriggerConditionOrigin, distalPrice_Pre, proximalPrice_Pre , distalPrice_Curr, proximalPrice_Curr, Index_Curr , OBValidGlobal, OBValidDis, MitigationLvL, ShowAll, Show, ColorZone) =>
OBType (string)
TriggerConditionOrigin (bool)
distalPrice_Pre (float)
proximalPrice_Pre (float)
distalPrice_Curr (float)
proximalPrice_Curr (float)
Index_Curr (int)
OBValidGlobal (bool)
OBValidDis (int)
MitigationLvL (string)
ShowAll (bool)
Show (bool)
ColorZone (color)
In this example, various parameters are defined to detect overlapping zones and draw them on the chart. Based on these settings, the overlapping areas will be automatically drawn on the chart.
OBType : All order blocks are summarized into two types: "Supply" and "Demand." You should input your Current order block type in this parameter. Enter "Demand" for drawing demand zones and "Supply" for drawing supply zones.
TriggerConditionOrigin : Input the condition under which you want the Current order block to be drawn in this parameter.
distalPrice_Pre : Generally, if each zone is formed by two lines, the farthest line from the price is termed Pervious "Distal." This input receives the price of the "Distal" line.
proximalPrice_Pre : Generally, if each zone is formed by two lines, the nearest line to the price is termed Previous "Proximal" line.
distalPrice_Curr : Generally, if each zone is formed by two lines, the farthest line from the price is termed Current "Distal." This input receives the price of the "Distal" line.
proximalPrice_Curr : Generally, if each zone is formed by two lines, the nearest line to the price is termed Current "Proximal" line.
Index_Curr : This input receives the value of the "bar_index" at the beginning of the order block. You should store the "bar_index" value at the occurrence of the condition for the Current order block to be drawn and input it here.
OBValidGlobal : This parameter is a boolean in which you can enter the condition that you want to execute to stop drawing the block order. If you do not have a special condition, you should set it to True.
OBValidDis : Order blocks continue to be drawn until a new order block is drawn or the order block is "Mitigate." You can specify how many candles after their initiation order blocks should continue. If you want no limitation, enter the number 4998.
MitigationLvL : This parameter is a string. Its inputs are one of "Proximal", "Distal" or "50 % OB" modes, which you can enter according to your needs. The "50 % OB" line is the middle line between distal and proximal.
ShowAll : This is a boolean parameter, if it is "true" the entire order of blocks will be displayed, and if it is "false" only the last block order will be displayed.
Show : You may need to manage whether to display or hide order blocks. When this input is "On", order blocks are displayed, and when it's "Off", order blocks are not displayed.
ColorZone : You can input your preferred color for drawing order blocks.
🟣 Output
Mitigation Alerts : This library allows you to leverage Mitigation Alerts to detect specific conditions that could lead to trend reversals. These alerts help you react promptly in your trades, ensuring better management of market shifts.
🔵 Conclusion
The Pine Script library provided is a powerful tool for technical analysis, especially in the ICT style. It enables you to detect overlapping zones between Order Blocks and other significant areas like Breaker Blocks and Fair Value Gaps, improving your trading strategies. By utilizing this tool, you can perform more precise analysis and manage risks effectively in your trades.
offline_detection Library
Description:
Boolean and alert functions that check if the latest user-selected symbol 'sym' has started printing. Alerts trigger by bar close.
Usage:
Mainly for 24/7 crypto exchanges. If an exchange you have alerts on goes offline, the alerts will not trigger. The offline alert is an alert to alert you of that. It's best to create the alerts while on "CRYPTOCAP:TOTAL" because it has the least downtime. The exchange you want alerts on is controlled by the 'sym' parameter. The alerts need to be enabled yourself.
Limitations:
The alerts may be triggered by no volume in a bar, so it's best to set it on timeframes higher than 1 minute. Alerts are not enabled in libraries so the functions must be imported or copied into another script. alert.freq cannot be changed by input because it becomes a series string in a function. dynamic_requests must be true to export functions using `request.*()` calls.
Example:
import NeoButane/offline_detection/1
thing = "COINBASE:BTCUSD"
offline_detection.offlineAlertNoSpam(thing)
offline_detection.onlineAlert(thing)
warningsign()
Library "offline_detection"
Creates alerts for the user-selected symbol by checking if its latest bar is current by comparing it against another chart.
isItDown(sym)
Checks if 'sym' is offline by requesting time of 'sym'.
Parameters:
sym (simple string) : (const string) The user-selected symbol in the form of "PREFIX:TICKER".
Returns: True if time of 'sym' is not available.
isItDownNoSpam(sym)
Checks if 'sym' is offline by requesting time of 'sym' once.
Parameters:
sym (simple string) : (const string) The user-selected symbol in the form of "PREFIX:TICKER".
Returns: True if time of 'sym' is not available and it was available in the previous bar close.
isItUp(sym)
Checks if 'sym' is online after being offline by using isItDown().
Parameters:
sym (simple string) : (const string) The user-selected symbol in the form of "PREFIX:TICKER".
Returns: True if time of 'sym' is available in the current bar but wasn't prior.
offlineAlert(sym)
Checks if isItDown() is true.
Parameters:
sym (simple string) : (const string) The user-selected symbol in the form of "PREFIX:TICKER".
Returns: An alert when the symbol is not online and the time in UTC. This will continue triggering every bar close until the symbol is online.
offlineAlertNoSpam(sym)
Checks if isItDown() is true.
Parameters:
sym (simple string) : (const string) The user-selected symbol in the form of "PREFIX:TICKER".
Returns: An alert when the symbol is not online and the time in UTC.
onlineAlert(sym)
Checks if isItUp() is true.
Parameters:
sym (simple string) : (const string) The user-selected symbol in the form of "PREFIX:TICKER".
Returns: An alert when the symbol is now online and the time in UTC.
warningsign()
Checks if the current chart is "CRYPTOCAP:TOTAL".
Returns: A reminder on the chart.
SpectrumLibrary "Spectrum"
This library includes spectrum analysis tools such as the Fast Fourier Transform (FFT).
method toComplex(data, polar)
Creates an array of complex type objects from a float type array.
Namespace types: array
Parameters:
data (array) : The float type array of input data.
polar (bool) : Initialization coordinates; the default is false (cartesian).
Returns: The complex type array of converted data.
method sAdd(data, value, end, start, step)
Performs scalar addition of a given float type array and a simple float value.
Namespace types: array
Parameters:
data (array) : The float type array of input data.
value (float) : The simple float type value to be added.
end (int) : The last index of the input array (exclusive) on which the operation is performed.
start (int) : The first index of the input array (inclusive) on which the operation is performed; the default value is 0.
step (int) : The step by which the function iterates over the input data array between the specified boundaries; the default value is 1.
Returns: The modified input array.
method sMult(data, value, end, start, step)
Performs scalar multiplication of a given float type array and a simple float value.
Namespace types: array
Parameters:
data (array) : The float type array of input data.
value (float) : The simple float type value to be added.
end (int) : The last index of the input array (exclusive) on which the operation is performed.
start (int) : The first index of the input array (inclusive) on which the operation is performed; the default value is 0.
step (int) : The step by which the function iterates over the input data array between the specified boundaries; the default value is 1.
Returns: The modified input array.
method eMult(data, data02, end, start, step)
Performs elementwise multiplication of two given complex type arrays.
Namespace types: array
Parameters:
data (array type from RezzaHmt/Complex/1) : the first complex type array of input data.
data02 (array type from RezzaHmt/Complex/1) : The second complex type array of input data.
end (int) : The last index of the input arrays (exclusive) on which the operation is performed.
start (int) : The first index of the input arrays (inclusive) on which the operation is performed; the default value is 0.
step (int) : The step by which the function iterates over the input data array between the specified boundaries; the default value is 1.
Returns: The modified first input array.
method eCon(data, end, start, step)
Performs elementwise conjugation on a given complex type array.
Namespace types: array
Parameters:
data (array type from RezzaHmt/Complex/1) : The complex type array of input data.
end (int) : The last index of the input array (exclusive) on which the operation is performed.
start (int) : The first index of the input array (inclusive) on which the operation is performed; the default value is 0.
step (int) : The step by which the function iterates over the input data array between the specified boundaries; the default value is 1.
Returns: The modified input array.
method zeros(length)
Creates a complex type array of zeros.
Namespace types: series int, simple int, input int, const int
Parameters:
length (int) : The size of array to be created.
method bitReverse(data)
Rearranges a complex type array based on the bit-reverse permutations of its size after zero-padding.
Namespace types: array
Parameters:
data (array type from RezzaHmt/Complex/1) : The complex type array of input data.
Returns: The modified input array.
method R2FFT(data, inverse)
Calculates Fourier Transform of a time series using Cooley-Tukey Radix-2 Decimation in Time FFT algorithm, wikipedia.org
Namespace types: array
Parameters:
data (array type from RezzaHmt/Complex/1) : The complex type array of input data.
inverse (int) : Set to -1 for FFT and to 1 for iFFT.
Returns: The modified input array containing the FFT result.
method LBFFT(data, inverse)
Calculates Fourier Transform of a time series using Leo Bluestein's FFT algorithm, wikipedia.org This function is nearly 4 times slower than the R2FFT function in practice.
Namespace types: array
Parameters:
data (array type from RezzaHmt/Complex/1) : The complex type array of input data.
inverse (int) : Set to -1 for FFT and to 1 for iFFT.
Returns: The modified input array containing the FFT result.
method DFT(data, inverse)
This is the original DFT algorithm. It is not suggested to be used regularly.
Namespace types: array
Parameters:
data (array type from RezzaHmt/Complex/1) : The complex type array of input data.
inverse (int) : Set to -1 for DFT and to 1 for iDFT.
Returns: The complex type array of DFT result.
COMET_Scanner_Library_FINALLibrary "COMET_Scanner_Library"
- A Trader's Edge (ATE)_Library was created to assist in constructing COM Scanners
TickerIDs(_string)
TickerIDs: You must form this single tickerID input string exactly as described in the scripts info panel (little gray 'i' that
is circled at the end of the settings in the settings/input panel that you can hover your cursor over this 'i' to read the
details of that particular input). IF the string is formed correctly then it will break up this single string parameter into
a total of 40 separate strings which will be all of the tickerIDs that the script is using in your COM Scanner.
Parameters:
_string (simple string) : (string)
A maximum of 40 Tickers (ALL joined as 1 string for the input parameter) that is formulated EXACTLY as described
within the tooltips of the TickerID inputs in my COM Scanner scripts:
assets = input.text_area(tIDs, title="TickerIDs (MUST READ TOOLTIP)", group=g2, tooltip="Accepts 40 TICKERID's
for each copy of the script on the chart. *** MUST FORMAT THIS WAY *** Each FULL tickerID
(ie 'Exchange:ticker') must be separated by A SINGLE BLANK SPACE for correct formatting. The blank space tells
the script where to break off the ticker to assign it to a variable to be used later in the script. So this input
will be a single string constructed from up to 40 tickerID's with a space between each tickerID
(ie. 'BINANCE:BTCUSDT BINANCE:SXPUSDT BINANCE:XRPUSDT').", display=display.none)
Returns: Returns 40 output variables in the tuple (ie. between the ' ') with the separated TickerIDs,
Locations(_firstLocation)
Locations: This function is used when there's a desire to print an assets ALERT LABELS. A set Location on the scale is assigned to each asset.
This is created so that if a lot of alerts are triggered, they will stay relatively visible and not overlap each other.
If you set your '_firstLocation' parameter as 1, since there are a max of 40 assets that can be scanned, the 1st asset's location
is assigned the value in the '_firstLocation' parameter, the 2nd asset's location is the (1st asset's location+1)...and so on.
Parameters:
_firstLocation (simple int) : (simple int)
Optional (starts at 1 if no parameter added).
Location that you want the first asset to print its label if is triggered to do so.
ie. loc2=loc1+1, loc3=loc2+1, etc.
Returns: Returns 40 variables for the locations for alert labels
LabelSize(_barCnt, _lblSzRfrnce)
INVALID TICKERIDs: This is to add a table in the middle right of your chart that prints all the TickerID's that were either not formulated
correctly in the '_source' input or that is not a valid symbol and should be changed.
LABEL SIZES: This function sizes your Alert Trigger Labels according to the amount of Printed Bars the chart has printed within
a set time period, while also keeping in mind the smallest relative reference size you input in the 'lblSzRfrnceInput'
parameter of this function. A HIGHER % of Printed Bars(aka...more trades occurring for that asset on the exchange),
the LARGER the Name Label will print, potentially showing you the better opportunities on the exchange to avoid
exchange manipulation liquidations.
*** SHOULD NOT be used as size of labels that are your asset Name Labels next to each asset's Line Plot...
if your COM Scanner includes these as you want these to be the same size for every asset so the larger ones dont cover the
smaller ones if the plots are all close to each other ***
Parameters:
_barCnt (float) : (float)
Get the 1st variable('barCnt') from the Security function's tuple and input it as this functions 1st input
parameter which will directly affect the size of the 2nd output variable ('alertTrigLabel') that is also outputted by this function.
_lblSzRfrnce (string) : (string)
Optional (if parameter not included, it defaults to size.small). This will be the size of the variable outputted
by this function named 'assetNameLabel' BUT also affects the size of the output variable 'alertTrigLabel' as it uses this parameter's size
as the smallest size for 'alertTrigLabel' then uses the '_barCnt' parameter to determine the next sizes up depending on the "_barCnt" value.
Returns: ( )
Returns 2 variables:
1st output variable ('AssetNameLabel') is assigned to the size of the 'lblSzRfrnceInput' parameter.
2nd output variable('alertTrigLabel') can be of variying sizes depending on the 'barCnt' parameter...BUT the smallest
size possible for the 2nd output variable ('alertTrigLabel') will be the size set in the 'lblSzRfrnceInput' parameter.
InvalidTickerIDs(_close, _securityTickerid, _invalidArray, _tablePosition, _stackVertical)
Parameters:
_close (float)
_securityTickerid (string)
_invalidArray (array)
_tablePosition (simple string)
_stackVertical (simple bool)
PrintedBarCount(_time, _barCntLength, _barCntPercentMin)
The Printed BarCount Filter looks back a User Defined amount of minutes and calculates the % of bars that have printed
out of the TOTAL amount of bars that COULD HAVE been printed within the same amount of time.
Parameters:
_time (int) : (int)
The time associated with the chart of the particular asset that is being screened at that point.
_barCntLength (int) : (int)
The amount of time (IN MINUTES) that you want the logic to look back at to calculate the % of bars that have actually
printed in the span of time you input into this parameter.
_barCntPercentMin (int) : (int)
The minimum % of Printed Bars of the asset being screened has to be GREATER than the value set in this parameter
for the output variable 'bc_gtg' to be true.
Returns: ( )
Returns 2 outputs:
1st is the % of Printed Bars that have printed within the within the span of time you input in the '_barCntLength' parameter.
2nd is true/false according to if the Printed BarCount % is above the threshold that you input into the '_barCntPercentMin' parameter.
COM_Scanner_LibraryLibrary "COM_Scanner_Library"
- A Trader's Edge (ATE)_Library was created to assist in constructing COM Scanners
TickerIDs(_string)
TickerIDs: You must form this single tickerID input string exactly as described in the scripts info panel (little gray 'i' that
is circled at the end of the settings in the settings/input panel that you can hover your cursor over this 'i' to read the
details of that particular input). IF the string is formed correctly then it will break up this single string parameter into
a total of 40 separate strings which will be all of the tickerIDs that the script is using in your COM Scanner.
Parameters:
_string (simple string) : (string)
A maximum of 40 Tickers (ALL joined as 1 string for the input parameter) that is formulated EXACTLY as described
within the tooltips of the TickerID inputs in my COM Scanner scripts:
assets = input.text_area(tIDs, title="TickerIDs (MUST READ TOOLTIP)", group=g2, tooltip="Accepts 40 TICKERID's
for each copy of the script on the chart. *** MUST FORMAT THIS WAY *** Each FULL tickerID
(ie 'Exchange:ticker') must be separated by A SINGLE BLANK SPACE for correct formatting. The blank space tells
the script where to break off the ticker to assign it to a variable to be used later in the script. So this input
will be a single string constructed from up to 40 tickerID's with a space between each tickerID
(ie. 'BINANCE:BTCUSDT BINANCE:SXPUSDT BINANCE:XRPUSDT').", display=display.none)
Returns: Returns 40 output variables in the tuple (ie. between the ' ') with the separated TickerIDs,
Locations(_firstLocation)
Locations: This function is used when there's a desire to print an assets ALERT LABELS. A set Location on the scale is assigned to each asset.
This is created so that if a lot of alerts are triggered, they will stay relatively visible and not overlap each other.
If you set your '_firstLocation' parameter as 1, since there are a max of 40 assets that can be scanned, the 1st asset's location
is assigned the value in the '_firstLocation' parameter, the 2nd asset's location is the (1st asset's location+1)...and so on.
Parameters:
_firstLocation (simple int) : (simple int)
Optional (starts at 1 if no parameter added).
Location that you want the first asset to print its label if is triggered to do so.
ie. loc2=loc1+1, loc3=loc2+1, etc.
Returns: Returns 40 variables for the locations for alert labels
LabelSize(_barCnt, _lblSzRfrnce)
INVALID TICKERIDs: This is to add a table in the middle right of your chart that prints all the TickerID's that were either not formulated
correctly in the '_source' input or that is not a valid symbol and should be changed.
LABEL SIZES: This function sizes your Alert Trigger Labels according to the amount of Printed Bars the chart has printed within
a set time period, while also keeping in mind the smallest relative reference size you input in the 'lblSzRfrnceInput'
parameter of this function. A HIGHER % of Printed Bars(aka...more trades occurring for that asset on the exchange),
the LARGER the Name Label will print, potentially showing you the better opportunities on the exchange to avoid
exchange manipulation liquidations.
*** SHOULD NOT be used as size of labels that are your asset Name Labels next to each asset's Line Plot...
if your COM Scanner includes these as you want these to be the same size for every asset so the larger ones dont cover the
smaller ones if the plots are all close to each other ***
Parameters:
_barCnt (float) : (float)
Get the 1st variable('barCnt') from the Security function's tuple and input it as this functions 1st input
parameter which will directly affect the size of the 2nd output variable ('alertTrigLabel') that is also outputted by this function.
_lblSzRfrnce (string) : (string)
Optional (if parameter not included, it defaults to size.small). This will be the size of the variable outputted
by this function named 'assetNameLabel' BUT also affects the size of the output variable 'alertTrigLabel' as it uses this parameter's size
as the smallest size for 'alertTrigLabel' then uses the '_barCnt' parameter to determine the next sizes up depending on the "_barCnt" value.
Returns: ( )
Returns 2 variables:
1st output variable ('AssetNameLabel') is assigned to the size of the 'lblSzRfrnceInput' parameter.
2nd output variable('alertTrigLabel') can be of variying sizes depending on the 'barCnt' parameter...BUT the smallest
size possible for the 2nd output variable ('alertTrigLabel') will be the size set in the 'lblSzRfrnceInput' parameter.
InvalidTickerIDs(_close, _securityTickerid, _invalidArray, _tablePosition, _stackVertical)
Parameters:
_close (float)
_securityTickerid (string)
_invalidArray (array)
_tablePosition (simple string)
_stackVertical (simple bool)
PrintedBarCount(_time, _barCntLength, _barCntPercentMin)
The Printed BarCount Filter looks back a User Defined amount of minutes and calculates the % of bars that have printed
out of the TOTAL amount of bars that COULD HAVE been printed within the same amount of time.
Parameters:
_time (int) : (int)
The time associated with the chart of the particular asset that is being screened at that point.
_barCntLength (int) : (int)
The amount of time (IN MINUTES) that you want the logic to look back at to calculate the % of bars that have actually
printed in the span of time you input into this parameter.
_barCntPercentMin (int) : (int)
The minimum % of Printed Bars of the asset being screened has to be GREATER than the value set in this parameter
for the output variable 'bc_gtg' to be true.
Returns: ( )
Returns 2 outputs:
1st is the % of Printed Bars that have printed within the within the span of time you input in the '_barCntLength' parameter.
2nd is true/false according to if the Printed BarCount % is above the threshold that you input into the '_barCntPercentMin' parameter.
JSONWebhooksLibrary "JSONWebhooks"
TODO: add library description here
method buildWebhookJson(msg, constants)
Builds the final JSON payload from a webhookMessage type.
Namespace types: webhookMessage
Parameters:
msg (webhookMessage) : (webhookMessage) A prepared webhookMessage.
constants (CONSTANTS)
Returns: A JSON Payload.
method buildTakeProfitJson(msg)
Builds the takeProfit JSON message to be used in a webhook message.
Namespace types: takeProfitMessage
Parameters:
msg (takeProfitMessage) : (takeProfitMessage)
Returns: A JSON takeProfit payload.
method buildStopLossJson(msg, constants)
Builds the stopLoss JSON message to be used in a webhook message.
Namespace types: stopLossMessage
Parameters:
msg (stopLossMessage) : (stopLossMessage)
constants (CONSTANTS)
Returns: A JSON stopLoss payload.
CONSTANTS
Constants for payload values.
Fields:
ACTION_BUY (series string)
ACTION_SELL (series string)
ACTION_EXIT (series string)
ACTION_CANCEL (series string)
ACTION_ADD (series string)
SENTIMENT_BULLISH (series string)
SENTIMENT_BEARISH (series string)
SENTIMENT_LONG (series string)
SENTIMENT_SHORT (series string)
SENTIMENT_FLAT (series string)
STOP_LOSS_TYPE_STOP (series string)
STOP_LOSS_TYPE_STOP_LIMIT (series string)
STOP_LOSS_TYPE_TRAILING_STOP (series string)
webhookMessage
Final webhook message.
Fields:
ticker (series string)
action (series string)
sentiment (series string)
price (series float)
quantity (series float)
takeProfit (series string)
stopLoss (series float)
takeProfitMessage
Take profit message.
Fields:
limitPrice (series float)
percent (series float)
amount (series float)
stopLossMessage
Stop loss message.
Fields:
type (series string)
percent (series float)
amount (series float)
stopPrice (series float)
limitPrice (series float)
trailPrice (series float)
trailPercent (series float)
LightyearWebhookLibrary "LightyearWebhook"
This library provides functionality to create a webhook signal configuration for trading strategies.
It generates a JSON string with relevant trading information which can be sent to external systems.
signal_config(leverage, contract_size, token)
signal_config
@description Generates a JSON string containing the signal configuration for trading strategies. This includes
information about the symbol, order action, market position, amount, price, cost, fee, order ID,
trade timestamp, previous entry price, previous market position size, initial capital, leverage,
contract size, and strategy token.
Parameters:
leverage (int)
contract_size (int)
token (string)
Returns: string A JSON string containing the signal configuration.
CRSILibrary "CRSI"
Cumulative Relative Strength Index
crsi(length, cumlength, source)
Calculates cumulative relative strength index
Parameters:
length (simple int)
cumlength (int)
source (float)
Returns: crsi
PubLibUtilityLibrary "PubLibUtility"
utilities for indicator and strategy development
size(size)
size to string conversion
Parameters:
size (string)
Returns: const string
tab_pos(tab_pos)
table position to string conversion
Parameters:
tab_pos (string)
Returns: const string
time_string(time_in)
time to string conversion
Parameters:
time_in (int)
Returns: literal string
GraphLibrary "Graph"
Library to collect data and draw scatterplot and heatmap as graph
method init(this)
Initialise Quadrant Data
Namespace types: Quadrant
Parameters:
this (Quadrant) : Quadrant object that needs to be initialised
Returns: current Quadrant object
method init(this)
Initialise Graph Data
Namespace types: Graph
Parameters:
this (Graph) : Graph object that needs to be initialised with 4 Quadrants
Returns: current Graph object
method add(this, data)
Add coordinates to graph
Namespace types: Graph
Parameters:
this (Graph) : Graph object
data (Coordinate) : Coordinates containing x, y data
Returns: current Graph object
method calculate(this)
Calculation required for plotting the graph
Namespace types: Graph
Parameters:
this (Graph) : Graph object
Returns: current Graph object
method paint(this)
Draw graph
Namespace types: Graph
Parameters:
this (Graph) : Graph object
Returns: current Graph object
Coordinate
Coordinates of sample data
Fields:
xValue (series float) : x value of the sample data
yValue (series float) : y value of the sample data
Quadrant
Data belonging to particular quadrant
Fields:
coordinates (array) : Coordinates present in given quadrant
GraphProperties
Properties of Graph that needs to be drawn
Fields:
rows (series int) : Number of rows (y values) in each quadrant
columns (series int) : number of columns (x values) in each quadrant
graphtype (series GraphType) : Type of graph - scatterplot or heatmap
plotColor (series color) : color of plots or heatmap
plotSize (series string) : size of cells in the table
plotchar (series string) : Character to be printed for display of scatterplot
outliers (series int) : Excude the outlier percent of data from calculating the min and max
position (series string) : Table position
bgColor (series color) : graph background color
PlotRange
Range of a plot in terms of x and y values and the number of data points that fall within the Range
Fields:
minX (series float) : min range of X value
maxX (series float) : max range of X value
minY (series float) : min range of Y value
maxY (series float) : max range of Y value
count (series int) : number of samples in the range
Graph
Graph data and properties
Fields:
properties (GraphProperties) : Graph Properties object associated
quadrants (array) : Array containing 4 quadrant data
plotRanges (matrix) : range and count for each cell
xArray (array) : array of x values
yArray (array) : arrray of y values
PubLibPatternLibrary "PubLibPattern"
pattern conditions for indicator and strategy development
bear_5_0(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bearish 5-0 harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bull_5_0(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bullish 5-0 harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bear_abcd(bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bearish abcd harmonic pattern condition
Parameters:
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bull_abcd(bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bullish abcd harmonic pattern condition
Parameters:
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bear_alt_bat(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bearish alternate bat harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bull_alt_bat(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bullish alternate bat harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bear_bat(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bearish bat harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bull_bat(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bullish bat harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bear_butterfly(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bearish butterfly harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bull_butterfly(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bullish butterfly harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bear_cassiopeia_a(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bearish cassiopeia a harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bull_cassiopeia_a(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bullish cassiopeia a harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bear_cassiopeia_b(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bearish cassiopeia b harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bull_cassiopeia_b(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bullish cassiopeia b harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bear_cassiopeia_c(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bearish cassiopeia c harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bull_cassiopeia_c(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol)
bullish cassiopeia c harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
Returns: bool
bear_crab(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bearish crab harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bull_crab(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bullish crab harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bear_deep_crab(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bearish deep crab harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bull_deep_crab(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bullish deep crab harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bear_cypher(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, xc_low_tol, xc_up_tol)
bearish cypher harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
xc_low_tol (float)
xc_up_tol (float)
Returns: bool
bull_cypher(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, xc_low_tol, xc_up_tol)
bullish cypher harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
xc_low_tol (float)
xc_up_tol (float)
Returns: bool
bear_gartley(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bearish gartley harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bull_gartley(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, cd_low_tol, cd_up_tol, ad_low_tol, ad_up_tol)
bullish gartley harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
cd_low_tol (float)
cd_up_tol (float)
ad_low_tol (float)
ad_up_tol (float)
Returns: bool
bear_shark(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, xc_low_tol, xc_up_tol)
bearish shark harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
xc_low_tol (float)
xc_up_tol (float)
Returns: bool
bull_shark(ab_low_tol, ab_up_tol, bc_low_tol, bc_up_tol, xc_low_tol, xc_up_tol)
bullish shark harmonic pattern condition
Parameters:
ab_low_tol (float)
ab_up_tol (float)
bc_low_tol (float)
bc_up_tol (float)
xc_low_tol (float)
xc_up_tol (float)
Returns: bool
bear_three_drive(x1_low_tol, a1_low_tol, a1_up_tol, a2_low_tol, a2_up_tol, b2_low_tol, b2_up_tol, b3_low_tol, b3_upt_tol)
bearish three drive harmonic pattern condition
Parameters:
x1_low_tol (float)
a1_low_tol (float)
a1_up_tol (float)
a2_low_tol (float)
a2_up_tol (float)
b2_low_tol (float)
b2_up_tol (float)
b3_low_tol (float)
b3_upt_tol (float)
Returns: bool
bull_three_drive(x1_low_tol, a1_low_tol, a1_up_tol, a2_low_tol, a2_up_tol, b2_low_tol, b2_up_tol, b3_low_tol, b3_upt_tol)
bullish three drive harmonic pattern condition
Parameters:
x1_low_tol (float)
a1_low_tol (float)
a1_up_tol (float)
a2_low_tol (float)
a2_up_tol (float)
b2_low_tol (float)
b2_up_tol (float)
b3_low_tol (float)
b3_upt_tol (float)
Returns: bool
asc_broadening()
ascending broadening pattern condition
Returns: bool
broadening()
broadening pattern condition
Returns: bool
desc_broadening()
descending broadening pattern condition
Returns: bool
double_bot(low_tol, up_tol)
double bottom pattern condition
Parameters:
low_tol (float)
up_tol (float)
Returns: bool
double_top(low_tol, up_tol)
double top pattern condition
Parameters:
low_tol (float)
up_tol (float)
Returns: bool
triple_bot(low_tol, up_tol)
triple bottom pattern condition
Parameters:
low_tol (float)
up_tol (float)
Returns: bool
triple_top(low_tol, up_tol)
triple top pattern condition
Parameters:
low_tol (float)
up_tol (float)
Returns: bool
bear_elliot()
bearish elliot wave pattern condition
Returns: bool
bull_elliot()
bullish elliot wave pattern condition
Returns: bool
bear_alt_flag(ab_ratio, bc_ratio)
bearish alternate flag pattern condition
Parameters:
ab_ratio (float)
bc_ratio (float)
Returns: bool
bull_alt_flag(ab_ratio, bc_ratio)
bullish alternate flag pattern condition
Parameters:
ab_ratio (float)
bc_ratio (float)
Returns: bool
bear_flag(ab_ratio, bc_ratio, be_ratio)
bearish flag pattern condition
Parameters:
ab_ratio (float)
bc_ratio (float)
be_ratio (float)
Returns: bool
bull_flag(ab_ratio, bc_ratio, be_ratio)
bullish flag pattern condition
Parameters:
ab_ratio (float)
bc_ratio (float)
be_ratio (float)
Returns: bool
bear_asc_head_shoulders()
bearish ascending head and shoulders pattern condition
Returns: bool
bull_asc_head_shoulders()
bullish ascending head and shoulders pattern condition
Returns: bool
bear_desc_head_shoulders()
bearish descending head and shoulders pattern condition
Returns: bool
bull_desc_head_shoulders()
bullish descending head and shoulders pattern condition
Returns: bool
bear_head_shoulders()
bearish head and shoulders pattern condition
Returns: bool
bull_head_shoulders()
bullish head and shoulders pattern condition
Returns: bool
bear_pennant(ab_ratio, bc_ratio)
bearish pennant pattern condition
Parameters:
ab_ratio (float)
bc_ratio (float)
Returns: bool
bull_pennant(ab_ratio, bc_ratio)
bullish pennant pattern condition
Parameters:
ab_ratio (float)
bc_ratio (float)
Returns: bool
asc_wedge()
ascending wedge pattern condition
Returns: bool
desc_wedge()
descending wedge pattern condition
Returns: bool
wedge()
wedge pattern condition
Returns: bool
PubLibTrendLibrary "PubLibTrend"
trend, multi-part trend, double trend and multi-part double trend conditions for indicator and strategy development
rlut()
return line uptrend condition
Returns: bool
dt()
downtrend condition
Returns: bool
ut()
uptrend condition
Returns: bool
rldt()
return line downtrend condition
Returns: bool
dtop()
double top condition
Returns: bool
dbot()
double bottom condition
Returns: bool
rlut_1p()
1-part return line uptrend condition
Returns: bool
rlut_2p()
2-part return line uptrend condition
Returns: bool
rlut_3p()
3-part return line uptrend condition
Returns: bool
rlut_4p()
4-part return line uptrend condition
Returns: bool
rlut_5p()
5-part return line uptrend condition
Returns: bool
rlut_6p()
6-part return line uptrend condition
Returns: bool
rlut_7p()
7-part return line uptrend condition
Returns: bool
rlut_8p()
8-part return line uptrend condition
Returns: bool
rlut_9p()
9-part return line uptrend condition
Returns: bool
rlut_10p()
10-part return line uptrend condition
Returns: bool
rlut_11p()
11-part return line uptrend condition
Returns: bool
rlut_12p()
12-part return line uptrend condition
Returns: bool
rlut_13p()
13-part return line uptrend condition
Returns: bool
rlut_14p()
14-part return line uptrend condition
Returns: bool
rlut_15p()
15-part return line uptrend condition
Returns: bool
rlut_16p()
16-part return line uptrend condition
Returns: bool
rlut_17p()
17-part return line uptrend condition
Returns: bool
rlut_18p()
18-part return line uptrend condition
Returns: bool
rlut_19p()
19-part return line uptrend condition
Returns: bool
rlut_20p()
20-part return line uptrend condition
Returns: bool
rlut_21p()
21-part return line uptrend condition
Returns: bool
rlut_22p()
22-part return line uptrend condition
Returns: bool
rlut_23p()
23-part return line uptrend condition
Returns: bool
rlut_24p()
24-part return line uptrend condition
Returns: bool
rlut_25p()
25-part return line uptrend condition
Returns: bool
rlut_26p()
26-part return line uptrend condition
Returns: bool
rlut_27p()
27-part return line uptrend condition
Returns: bool
rlut_28p()
28-part return line uptrend condition
Returns: bool
rlut_29p()
29-part return line uptrend condition
Returns: bool
rlut_30p()
30-part return line uptrend condition
Returns: bool
dt_1p()
1-part downtrend condition
Returns: bool
dt_2p()
2-part downtrend condition
Returns: bool
dt_3p()
3-part downtrend condition
Returns: bool
dt_4p()
4-part downtrend condition
Returns: bool
dt_5p()
5-part downtrend condition
Returns: bool
dt_6p()
6-part downtrend condition
Returns: bool
dt_7p()
7-part downtrend condition
Returns: bool
dt_8p()
8-part downtrend condition
Returns: bool
dt_9p()
9-part downtrend condition
Returns: bool
dt_10p()
10-part downtrend condition
Returns: bool
dt_11p()
11-part downtrend condition
Returns: bool
dt_12p()
12-part downtrend condition
Returns: bool
dt_13p()
13-part downtrend condition
Returns: bool
dt_14p()
14-part downtrend condition
Returns: bool
dt_15p()
15-part downtrend condition
Returns: bool
dt_16p()
16-part downtrend condition
Returns: bool
dt_17p()
17-part downtrend condition
Returns: bool
dt_18p()
18-part downtrend condition
Returns: bool
dt_19p()
19-part downtrend condition
Returns: bool
dt_20p()
20-part downtrend condition
Returns: bool
dt_21p()
21-part downtrend condition
Returns: bool
dt_22p()
22-part downtrend condition
Returns: bool
dt_23p()
23-part downtrend condition
Returns: bool
dt_24p()
24-part downtrend condition
Returns: bool
dt_25p()
25-part downtrend condition
Returns: bool
dt_26p()
26-part downtrend condition
Returns: bool
dt_27p()
27-part downtrend condition
Returns: bool
dt_28p()
28-part downtrend condition
Returns: bool
dt_29p()
29-part downtrend condition
Returns: bool
dt_30p()
30-part downtrend condition
Returns: bool
ut_1p()
1-part uptrend condition
Returns: bool
ut_2p()
2-part uptrend condition
Returns: bool
ut_3p()
3-part uptrend condition
Returns: bool
ut_4p()
4-part uptrend condition
Returns: bool
ut_5p()
5-part uptrend condition
Returns: bool
ut_6p()
6-part uptrend condition
Returns: bool
ut_7p()
7-part uptrend condition
Returns: bool
ut_8p()
8-part uptrend condition
Returns: bool
ut_9p()
9-part uptrend condition
Returns: bool
ut_10p()
10-part uptrend condition
Returns: bool
ut_11p()
11-part uptrend condition
Returns: bool
ut_12p()
12-part uptrend condition
Returns: bool
ut_13p()
13-part uptrend condition
Returns: bool
ut_14p()
14-part uptrend condition
Returns: bool
ut_15p()
15-part uptrend condition
Returns: bool
ut_16p()
16-part uptrend condition
Returns: bool
ut_17p()
17-part uptrend condition
Returns: bool
ut_18p()
18-part uptrend condition
Returns: bool
ut_19p()
19-part uptrend condition
Returns: bool
ut_20p()
20-part uptrend condition
Returns: bool
ut_21p()
21-part uptrend condition
Returns: bool
ut_22p()
22-part uptrend condition
Returns: bool
ut_23p()
23-part uptrend condition
Returns: bool
ut_24p()
24-part uptrend condition
Returns: bool
ut_25p()
25-part uptrend condition
Returns: bool
ut_26p()
26-part uptrend condition
Returns: bool
ut_27p()
27-part uptrend condition
Returns: bool
ut_28p()
28-part uptrend condition
Returns: bool
ut_29p()
29-part uptrend condition
Returns: bool
ut_30p()
30-part uptrend condition
Returns: bool
rldt_1p()
1-part return line downtrend condition
Returns: bool
rldt_2p()
2-part return line downtrend condition
Returns: bool
rldt_3p()
3-part return line downtrend condition
Returns: bool
rldt_4p()
4-part return line downtrend condition
Returns: bool
rldt_5p()
5-part return line downtrend condition
Returns: bool
rldt_6p()
6-part return line downtrend condition
Returns: bool
rldt_7p()
7-part return line downtrend condition
Returns: bool
rldt_8p()
8-part return line downtrend condition
Returns: bool
rldt_9p()
9-part return line downtrend condition
Returns: bool
rldt_10p()
10-part return line downtrend condition
Returns: bool
rldt_11p()
11-part return line downtrend condition
Returns: bool
rldt_12p()
12-part return line downtrend condition
Returns: bool
rldt_13p()
13-part return line downtrend condition
Returns: bool
rldt_14p()
14-part return line downtrend condition
Returns: bool
rldt_15p()
15-part return line downtrend condition
Returns: bool
rldt_16p()
16-part return line downtrend condition
Returns: bool
rldt_17p()
17-part return line downtrend condition
Returns: bool
rldt_18p()
18-part return line downtrend condition
Returns: bool
rldt_19p()
19-part return line downtrend condition
Returns: bool
rldt_20p()
20-part return line downtrend condition
Returns: bool
rldt_21p()
21-part return line downtrend condition
Returns: bool
rldt_22p()
22-part return line downtrend condition
Returns: bool
rldt_23p()
23-part return line downtrend condition
Returns: bool
rldt_24p()
24-part return line downtrend condition
Returns: bool
rldt_25p()
25-part return line downtrend condition
Returns: bool
rldt_26p()
26-part return line downtrend condition
Returns: bool
rldt_27p()
27-part return line downtrend condition
Returns: bool
rldt_28p()
28-part return line downtrend condition
Returns: bool
rldt_29p()
29-part return line downtrend condition
Returns: bool
rldt_30p()
30-part return line downtrend condition
Returns: bool
dut()
double uptrend condition
Returns: bool
ddt()
double downtrend condition
Returns: bool
dut_1p()
1-part double uptrend condition
Returns: bool
dut_2p()
2-part double uptrend condition
Returns: bool
dut_3p()
3-part double uptrend condition
Returns: bool
dut_4p()
4-part double uptrend condition
Returns: bool
dut_5p()
5-part double uptrend condition
Returns: bool
dut_6p()
6-part double uptrend condition
Returns: bool
dut_7p()
7-part double uptrend condition
Returns: bool
dut_8p()
8-part double uptrend condition
Returns: bool
dut_9p()
9-part double uptrend condition
Returns: bool
dut_10p()
10-part double uptrend condition
Returns: bool
dut_11p()
11-part double uptrend condition
Returns: bool
dut_12p()
12-part double uptrend condition
Returns: bool
dut_13p()
13-part double uptrend condition
Returns: bool
dut_14p()
14-part double uptrend condition
Returns: bool
dut_15p()
15-part double uptrend condition
Returns: bool
dut_16p()
16-part double uptrend condition
Returns: bool
dut_17p()
17-part double uptrend condition
Returns: bool
dut_18p()
18-part double uptrend condition
Returns: bool
dut_19p()
19-part double uptrend condition
Returns: bool
dut_20p()
20-part double uptrend condition
Returns: bool
dut_21p()
21-part double uptrend condition
Returns: bool
dut_22p()
22-part double uptrend condition
Returns: bool
dut_23p()
23-part double uptrend condition
Returns: bool
dut_24p()
24-part double uptrend condition
Returns: bool
dut_25p()
25-part double uptrend condition
Returns: bool
dut_26p()
26-part double uptrend condition
Returns: bool
dut_27p()
27-part double uptrend condition
Returns: bool
dut_28p()
28-part double uptrend condition
Returns: bool
dut_29p()
29-part double uptrend condition
Returns: bool
dut_30p()
30-part double uptrend condition
Returns: bool
ddt_1p()
1-part double downtrend condition
Returns: bool
ddt_2p()
2-part double downtrend condition
Returns: bool
ddt_3p()
3-part double downtrend condition
Returns: bool
ddt_4p()
4-part double downtrend condition
Returns: bool
ddt_5p()
5-part double downtrend condition
Returns: bool
ddt_6p()
6-part double downtrend condition
Returns: bool
ddt_7p()
7-part double downtrend condition
Returns: bool
ddt_8p()
8-part double downtrend condition
Returns: bool
ddt_9p()
9-part double downtrend condition
Returns: bool
ddt_10p()
10-part double downtrend condition
Returns: bool
ddt_11p()
11-part double downtrend condition
Returns: bool
ddt_12p()
12-part double downtrend condition
Returns: bool
ddt_13p()
13-part double downtrend condition
Returns: bool
ddt_14p()
14-part double downtrend condition
Returns: bool
ddt_15p()
15-part double downtrend condition
Returns: bool
ddt_16p()
16-part double downtrend condition
Returns: bool
ddt_17p()
17-part double downtrend condition
Returns: bool
ddt_18p()
18-part double downtrend condition
Returns: bool
ddt_19p()
19-part double downtrend condition
Returns: bool
ddt_20p()
20-part double downtrend condition
Returns: bool
ddt_21p()
21-part double downtrend condition
Returns: bool
ddt_22p()
22-part double downtrend condition
Returns: bool
ddt_23p()
23-part double downtrend condition
Returns: bool
ddt_24p()
24-part double downtrend condition
Returns: bool
ddt_25p()
25-part double downtrend condition
Returns: bool
ddt_26p()
26-part double downtrend condition
Returns: bool
ddt_27p()
27-part double downtrend condition
Returns: bool
ddt_28p()
28-part double downtrend condition
Returns: bool
ddt_29p()
29-part double downtrend condition
Returns: bool
ddt_30p()
30-part double downtrend condition
Returns: bool
PubLibSwingLibrary "PubLibSwing"
swing high and swing low conditions, prices, bar indices and range ratios for indicator and strategy development
sh()
swing high condition
Returns: bool
sl()
swing low condition
Returns: bool
shbi(occ)
swing high bar index, condition occurrence n
Parameters:
occ (simple int)
Returns: int
slbi(occ)
swing low bar index, condition occurrence n
Parameters:
occ (simple int)
Returns: int
shcp(occ)
swing high close price, condition occurrence n
Parameters:
occ (simple int)
Returns: float
slcp(occ)
swing low close price, condition occurrence n
Parameters:
occ (simple int)
Returns: float
shp(occ)
swing high price, condition occurrence n
Parameters:
occ (simple int)
Returns: float
slp(occ)
swing low price, condition occurrence n
Parameters:
occ (simple int)
Returns: float
shpbi(occ)
swing high price bar index, condition occurrence n
Parameters:
occ (simple int)
Returns: int
slpbi(occ)
swing low price bar index, condition occurrence n
Parameters:
occ (simple int)
Returns: int
shrr(occ)
swing high range ratio, condition occurrence n
Parameters:
occ (simple int)
Returns: float
slrr(occ)
swing low range ratio, condition occurrence n
Parameters:
occ (simple int)
Returns: float
PubLibCandleTrendLibrary "PubLibCandleTrend"
candle trend, multi-part candle trend, multi-part green/red candle trend, double candle trend and multi-part double candle trend conditions for indicator and strategy development
chh()
candle higher high condition
Returns: bool
chl()
candle higher low condition
Returns: bool
clh()
candle lower high condition
Returns: bool
cll()
candle lower low condition
Returns: bool
cdt()
candle double top condition
Returns: bool
cdb()
candle double bottom condition
Returns: bool
gc()
green candle condition
Returns: bool
gchh()
green candle higher high condition
Returns: bool
gchl()
green candle higher low condition
Returns: bool
gclh()
green candle lower high condition
Returns: bool
gcll()
green candle lower low condition
Returns: bool
gcdt()
green candle double top condition
Returns: bool
gcdb()
green candle double bottom condition
Returns: bool
rc()
red candle condition
Returns: bool
rchh()
red candle higher high condition
Returns: bool
rchl()
red candle higher low condition
Returns: bool
rclh()
red candle lower high condition
Returns: bool
rcll()
red candle lower low condition
Returns: bool
rcdt()
red candle double top condition
Returns: bool
rcdb()
red candle double bottom condition
Returns: bool
chh_1p()
1-part candle higher high condition
Returns: bool
chh_2p()
2-part candle higher high condition
Returns: bool
chh_3p()
3-part candle higher high condition
Returns: bool
chh_4p()
4-part candle higher high condition
Returns: bool
chh_5p()
5-part candle higher high condition
Returns: bool
chh_6p()
6-part candle higher high condition
Returns: bool
chh_7p()
7-part candle higher high condition
Returns: bool
chh_8p()
8-part candle higher high condition
Returns: bool
chh_9p()
9-part candle higher high condition
Returns: bool
chh_10p()
10-part candle higher high condition
Returns: bool
chh_11p()
11-part candle higher high condition
Returns: bool
chh_12p()
12-part candle higher high condition
Returns: bool
chh_13p()
13-part candle higher high condition
Returns: bool
chh_14p()
14-part candle higher high condition
Returns: bool
chh_15p()
15-part candle higher high condition
Returns: bool
chh_16p()
16-part candle higher high condition
Returns: bool
chh_17p()
17-part candle higher high condition
Returns: bool
chh_18p()
18-part candle higher high condition
Returns: bool
chh_19p()
19-part candle higher high condition
Returns: bool
chh_20p()
20-part candle higher high condition
Returns: bool
chh_21p()
21-part candle higher high condition
Returns: bool
chh_22p()
22-part candle higher high condition
Returns: bool
chh_23p()
23-part candle higher high condition
Returns: bool
chh_24p()
24-part candle higher high condition
Returns: bool
chh_25p()
25-part candle higher high condition
Returns: bool
chh_26p()
26-part candle higher high condition
Returns: bool
chh_27p()
27-part candle higher high condition
Returns: bool
chh_28p()
28-part candle higher high condition
Returns: bool
chh_29p()
29-part candle higher high condition
Returns: bool
chh_30p()
30-part candle higher high condition
Returns: bool
chl_1p()
1-part candle higher low condition
Returns: bool
chl_2p()
2-part candle higher low condition
Returns: bool
chl_3p()
3-part candle higher low condition
Returns: bool
chl_4p()
4-part candle higher low condition
Returns: bool
chl_5p()
5-part candle higher low condition
Returns: bool
chl_6p()
6-part candle higher low condition
Returns: bool
chl_7p()
7-part candle higher low condition
Returns: bool
chl_8p()
8-part candle higher low condition
Returns: bool
chl_9p()
9-part candle higher low condition
Returns: bool
chl_10p()
10-part candle higher low condition
Returns: bool
chl_11p()
11-part candle higher low condition
Returns: bool
chl_12p()
12-part candle higher low condition
Returns: bool
chl_13p()
13-part candle higher low condition
Returns: bool
chl_14p()
14-part candle higher low condition
Returns: bool
chl_15p()
15-part candle higher low condition
Returns: bool
chl_16p()
16-part candle higher low condition
Returns: bool
chl_17p()
17-part candle higher low condition
Returns: bool
chl_18p()
18-part candle higher low condition
Returns: bool
chl_19p()
19-part candle higher low condition
Returns: bool
chl_20p()
20-part candle higher low condition
Returns: bool
chl_21p()
21-part candle higher low condition
Returns: bool
chl_22p()
22-part candle higher low condition
Returns: bool
chl_23p()
23-part candle higher low condition
Returns: bool
chl_24p()
24-part candle higher low condition
Returns: bool
chl_25p()
25-part candle higher low condition
Returns: bool
chl_26p()
26-part candle higher low condition
Returns: bool
chl_27p()
27-part candle higher low condition
Returns: bool
chl_28p()
28-part candle higher low condition
Returns: bool
chl_29p()
29-part candle higher low condition
Returns: bool
chl_30p()
30-part candle higher low condition
Returns: bool
clh_1p()
1-part candle lower high condition
Returns: bool
clh_2p()
2-part candle lower high condition
Returns: bool
clh_3p()
3-part candle lower high condition
Returns: bool
clh_4p()
4-part candle lower high condition
Returns: bool
clh_5p()
5-part candle lower high condition
Returns: bool
clh_6p()
6-part candle lower high condition
Returns: bool
clh_7p()
7-part candle lower high condition
Returns: bool
clh_8p()
8-part candle lower high condition
Returns: bool
clh_9p()
9-part candle lower high condition
Returns: bool
clh_10p()
10-part candle lower high condition
Returns: bool
clh_11p()
11-part candle lower high condition
Returns: bool
clh_12p()
12-part candle lower high condition
Returns: bool
clh_13p()
13-part candle lower high condition
Returns: bool
clh_14p()
14-part candle lower high condition
Returns: bool
clh_15p()
15-part candle lower high condition
Returns: bool
clh_16p()
16-part candle lower high condition
Returns: bool
clh_17p()
17-part candle lower high condition
Returns: bool
clh_18p()
18-part candle lower high condition
Returns: bool
clh_19p()
19-part candle lower high condition
Returns: bool
clh_20p()
20-part candle lower high condition
Returns: bool
clh_21p()
21-part candle lower high condition
Returns: bool
clh_22p()
22-part candle lower high condition
Returns: bool
clh_23p()
23-part candle lower high condition
Returns: bool
clh_24p()
24-part candle lower high condition
Returns: bool
clh_25p()
25-part candle lower high condition
Returns: bool
clh_26p()
26-part candle lower high condition
Returns: bool
clh_27p()
27-part candle lower high condition
Returns: bool
clh_28p()
28-part candle lower high condition
Returns: bool
clh_29p()
29-part candle lower high condition
Returns: bool
clh_30p()
30-part candle lower high condition
Returns: bool
cll_1p()
1-part candle lower low condition
Returns: bool
cll_2p()
2-part candle lower low condition
Returns: bool
cll_3p()
3-part candle lower low condition
Returns: bool
cll_4p()
4-part candle lower low condition
Returns: bool
cll_5p()
5-part candle lower low condition
Returns: bool
cll_6p()
6-part candle lower low condition
Returns: bool
cll_7p()
7-part candle lower low condition
Returns: bool
cll_8p()
8-part candle lower low condition
Returns: bool
cll_9p()
9-part candle lower low condition
Returns: bool
cll_10p()
10-part candle lower low condition
Returns: bool
cll_11p()
11-part candle lower low condition
Returns: bool
cll_12p()
12-part candle lower low condition
Returns: bool
cll_13p()
13-part candle lower low condition
Returns: bool
cll_14p()
14-part candle lower low condition
Returns: bool
cll_15p()
15-part candle lower low condition
Returns: bool
cll_16p()
16-part candle lower low condition
Returns: bool
cll_17p()
17-part candle lower low condition
Returns: bool
cll_18p()
18-part candle lower low condition
Returns: bool
cll_19p()
19-part candle lower low condition
Returns: bool
cll_20p()
20-part candle lower low condition
Returns: bool
cll_21p()
21-part candle lower low condition
Returns: bool
cll_22p()
22-part candle lower low condition
Returns: bool
cll_23p()
23-part candle lower low condition
Returns: bool
cll_24p()
24-part candle lower low condition
Returns: bool
cll_25p()
25-part candle lower low condition
Returns: bool
cll_26p()
26-part candle lower low condition
Returns: bool
cll_27p()
27-part candle lower low condition
Returns: bool
cll_28p()
28-part candle lower low condition
Returns: bool
cll_29p()
29-part candle lower low condition
Returns: bool
cll_30p()
30-part candle lower low condition
Returns: bool
gc_1p()
1-part green candle condition
Returns: bool
gc_2p()
2-part green candle condition
Returns: bool
gc_3p()
3-part green candle condition
Returns: bool
gc_4p()
4-part green candle condition
Returns: bool
gc_5p()
5-part green candle condition
Returns: bool
gc_6p()
6-part green candle condition
Returns: bool
gc_7p()
7-part green candle condition
Returns: bool
gc_8p()
8-part green candle condition
Returns: bool
gc_9p()
9-part green candle condition
Returns: bool
gc_10p()
10-part green candle condition
Returns: bool
gc_11p()
11-part green candle condition
Returns: bool
gc_12p()
12-part green candle condition
Returns: bool
gc_13p()
13-part green candle condition
Returns: bool
gc_14p()
14-part green candle condition
Returns: bool
gc_15p()
15-part green candle condition
Returns: bool
gc_16p()
16-part green candle condition
Returns: bool
gc_17p()
17-part green candle condition
Returns: bool
gc_18p()
18-part green candle condition
Returns: bool
gc_19p()
19-part green candle condition
Returns: bool
gc_20p()
20-part green candle condition
Returns: bool
gc_21p()
21-part green candle condition
Returns: bool
gc_22p()
22-part green candle condition
Returns: bool
gc_23p()
23-part green candle condition
Returns: bool
gc_24p()
24-part green candle condition
Returns: bool
gc_25p()
25-part green candle condition
Returns: bool
gc_26p()
26-part green candle condition
Returns: bool
gc_27p()
27-part green candle condition
Returns: bool
gc_28p()
28-part green candle condition
Returns: bool
gc_29p()
29-part green candle condition
Returns: bool
gc_30p()
30-part green candle condition
Returns: bool
rc_1p()
1-part red candle condition
Returns: bool
rc_2p()
2-part red candle condition
Returns: bool
rc_3p()
3-part red candle condition
Returns: bool
rc_4p()
4-part red candle condition
Returns: bool
rc_5p()
5-part red candle condition
Returns: bool
rc_6p()
6-part red candle condition
Returns: bool
rc_7p()
7-part red candle condition
Returns: bool
rc_8p()
8-part red candle condition
Returns: bool
rc_9p()
9-part red candle condition
Returns: bool
rc_10p()
10-part red candle condition
Returns: bool
rc_11p()
11-part red candle condition
Returns: bool
rc_12p()
12-part red candle condition
Returns: bool
rc_13p()
13-part red candle condition
Returns: bool
rc_14p()
14-part red candle condition
Returns: bool
rc_15p()
15-part red candle condition
Returns: bool
rc_16p()
16-part red candle condition
Returns: bool
rc_17p()
17-part red candle condition
Returns: bool
rc_18p()
18-part red candle condition
Returns: bool
rc_19p()
19-part red candle condition
Returns: bool
rc_20p()
20-part red candle condition
Returns: bool
rc_21p()
21-part red candle condition
Returns: bool
rc_22p()
22-part red candle condition
Returns: bool
rc_23p()
23-part red candle condition
Returns: bool
rc_24p()
24-part red candle condition
Returns: bool
rc_25p()
25-part red candle condition
Returns: bool
rc_26p()
26-part red candle condition
Returns: bool
rc_27p()
27-part red candle condition
Returns: bool
rc_28p()
28-part red candle condition
Returns: bool
rc_29p()
29-part red candle condition
Returns: bool
rc_30p()
30-part red candle condition
Returns: bool
cdut()
candle double uptrend condition
Returns: bool
cddt()
candle double downtrend condition
Returns: bool
cdut_1p()
1-part candle double uptrend condition
Returns: bool
cdut_2p()
2-part candle double uptrend condition
Returns: bool
cdut_3p()
3-part candle double uptrend condition
Returns: bool
cdut_4p()
4-part candle double uptrend condition
Returns: bool
cdut_5p()
5-part candle double uptrend condition
Returns: bool
cdut_6p()
6-part candle double uptrend condition
Returns: bool
cdut_7p()
7-part candle double uptrend condition
Returns: bool
cdut_8p()
8-part candle double uptrend condition
Returns: bool
cdut_9p()
9-part candle double uptrend condition
Returns: bool
cdut_10p()
10-part candle double uptrend condition
Returns: bool
cdut_11p()
11-part candle double uptrend condition
Returns: bool
cdut_12p()
12-part candle double uptrend condition
Returns: bool
cdut_13p()
13-part candle double uptrend condition
Returns: bool
cdut_14p()
14-part candle double uptrend condition
Returns: bool
cdut_15p()
15-part candle double uptrend condition
Returns: bool
cdut_16p()
16-part candle double uptrend condition
Returns: bool
cdut_17p()
17-part candle double uptrend condition
Returns: bool
cdut_18p()
18-part candle double uptrend condition
Returns: bool
cdut_19p()
19-part candle double uptrend condition
Returns: bool
cdut_20p()
20-part candle double uptrend condition
Returns: bool
cdut_21p()
21-part candle double uptrend condition
Returns: bool
cdut_22p()
22-part candle double uptrend condition
Returns: bool
cdut_23p()
23-part candle double uptrend condition
Returns: bool
cdut_24p()
24-part candle double uptrend condition
Returns: bool
cdut_25p()
25-part candle double uptrend condition
Returns: bool
cdut_26p()
26-part candle double uptrend condition
Returns: bool
cdut_27p()
27-part candle double uptrend condition
Returns: bool
cdut_28p()
28-part candle double uptrend condition
Returns: bool
cdut_29p()
29-part candle double uptrend condition
Returns: bool
cdut_30p()
30-part candle double uptrend condition
Returns: bool
cddt_1p()
1-part candle double downtrend condition
Returns: bool
cddt_2p()
2-part candle double downtrend condition
Returns: bool
cddt_3p()
3-part candle double downtrend condition
Returns: bool
cddt_4p()
4-part candle double downtrend condition
Returns: bool
cddt_5p()
5-part candle double downtrend condition
Returns: bool
cddt_6p()
6-part candle double downtrend condition
Returns: bool
cddt_7p()
7-part candle double downtrend condition
Returns: bool
cddt_8p()
8-part candle double downtrend condition
Returns: bool
cddt_9p()
9-part candle double downtrend condition
Returns: bool
cddt_10p()
10-part candle double downtrend condition
Returns: bool
cddt_11p()
11-part candle double downtrend condition
Returns: bool
cddt_12p()
12-part candle double downtrend condition
Returns: bool
cddt_13p()
13-part candle double downtrend condition
Returns: bool
cddt_14p()
14-part candle double downtrend condition
Returns: bool
cddt_15p()
15-part candle double downtrend condition
Returns: bool
cddt_16p()
16-part candle double downtrend condition
Returns: bool
cddt_17p()
17-part candle double downtrend condition
Returns: bool
cddt_18p()
18-part candle double downtrend condition
Returns: bool
cddt_19p()
19-part candle double downtrend condition
Returns: bool
cddt_20p()
20-part candle double downtrend condition
Returns: bool
cddt_21p()
21-part candle double downtrend condition
Returns: bool
cddt_22p()
22-part candle double downtrend condition
Returns: bool
cddt_23p()
23-part candle double downtrend condition
Returns: bool
cddt_24p()
24-part candle double downtrend condition
Returns: bool
cddt_25p()
25-part candle double downtrend condition
Returns: bool
cddt_26p()
26-part candle double downtrend condition
Returns: bool
cddt_27p()
27-part candle double downtrend condition
Returns: bool
cddt_28p()
28-part candle double downtrend condition
Returns: bool
cddt_29p()
29-part candle double downtrend condition
Returns: bool
cddt_30p()
30-part candle double downtrend condition
Returns: bool