GetPriceType

GetPriceType ();

Description

Returns the price type selected for the current symbol: "Last", "Bid", "Ask", or "Mark". Note that the last three are supported by non-Forex symbols only on intraday charts with time interval not greater than 15 days; on all other charts this function will always return "Last" for non-Forex symbols.

Example

AddLabel(yes, "The " + GetPricetype() + " price type is selected");

This script adds a chart label showing which price type is currently selected.

You may also like
MomentumPercentDiff
The Momentum Percent Diff is a momentum-based technical indicator. Unlike the regular Momentum ...
Tick Counter
Tick Counter is a feature available for charts using Tick aggregation. This feature shows ...
SlowRSI
The Slow Relative Strength Index is a version of the classic Relative Strength Index (RSI), ...