Constant for dividends adjustment type (dividends adjustment is applied).
Type
const string
See also
adjustment.noneadjustment.splitsticker.new()
Constant for none adjustment type (no adjustment is applied).
Type
const string
See also
adjustment.splitsadjustment.dividendsticker.new()
Constant for splits adjustment type (splits adjustment is applied).
Type
const string
See also
adjustment.noneadjustment.dividendsticker.new()
A named constant for use with the freq parameter of the alert() function.
All function calls trigger the alert.
Type
const string
See also
A named constant for use with the freq parameter of the alert() function.
The first function call during the bar triggers the alert.
Type
const string
See also
A named constant for use with the freq parameter of the alert() function.
The function call triggers the alert only when it occurs during the last script iteration of the real-time bar, when it closes.
Type
const string
See also
A constant to specify the value of the backadjustment parameter in ticker.new() and ticker.modify() functions.
Type
const backadjustment
See also
ticker.new()ticker.modify()backadjustment.onbackadjustment.off
A constant to specify the value of the backadjustment parameter in ticker.new() and ticker.modify() functions.
Type
const backadjustment
See also
ticker.new()ticker.modify()backadjustment.onbackadjustment.inherit
A constant to specify the value of the backadjustment parameter in ticker.new() and ticker.modify() functions.
Type
const backadjustment
See also
ticker.new()ticker.modify()backadjustment.inheritbackadjustment.off
Merge strategy for requested data. Data is merged continuously without gaps, all the gaps are filled with the previous nearest existing value.
Type
const barmerge_gaps
See also
request.security()barmerge.gaps_on
Merge strategy for requested data. Data is merged with possible gaps (na values).
Type
const barmerge_gaps
See also
request.security()barmerge.gaps_off
Merge strategy for the requested data position. Requested barset is merged with current barset in the order of sorting bars by their close time. This merge strategy disables effect of getting data from "future" on calculation on history.
Type
const barmerge_lookahead
See also
request.security()barmerge.lookahead_on
Merge strategy for the requested data position. Requested barset is merged with current barset in the order of sorting bars by their opening time. This merge strategy can lead to undesirable effect of getting data from "future" on calculation on history. This is unacceptable in backtesting strategies, but can be useful in indicators.
Type
const barmerge_lookahead
See also
request.security()barmerge.lookahead_off
Is a named constant for #00BCD4 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.orange
Is a named constant for #363A45 color.
Type
const color
See also
color.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #2962ff color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.tealcolor.aquacolor.orange
Is a named constant for #E040FB color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #787B86 color.
Type
const color
See also
color.blackcolor.silvercolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #4CAF50 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #00E676 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #880E4F color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #311B92 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #808000 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #FF9800 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aqua
Is a named constant for #9C27B0 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #F23645 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #B2B5BE color.
Type
const color
See also
color.blackcolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #089981 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.aquacolor.orange
Is a named constant for #FFFFFF color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.yellowcolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Is a named constant for #FDD835 color.
Type
const color
See also
color.blackcolor.silvercolor.graycolor.whitecolor.marooncolor.redcolor.purplecolor.fuchsiacolor.greencolor.limecolor.olivecolor.navycolor.bluecolor.tealcolor.aquacolor.orange
Arab Emirates Dirham.
Type
const string
See also
Argentine Pesos.
Type
const string
See also
Australian dollar.
Type
const string
See also
Bangladeshi Taka.
Type
const string
See also
Bahraini Dinar.
Type
const string
See also
Brazilian real.
Type
const string
See also
Bitcoin.
Type
const string
See also
Canadian dollar.
Type
const string
See also
Swiss franc.
Type
const string
See also
Chilean Peso.
Type
const string
See also
Chinese Yuan.
Type
const string
See also
Colombian Peso.
Type
const string
See also
Czech Koruna.
Type
const string
See also
Danish Krone.
Type
const string
See also
Egyptian pound.
Type
const string
See also
Ethereum.
Type
const string
See also
Euro.
Type
const string
See also
Pound sterling.
Type
const string
See also
Hong Kong dollar.
Type
const string
See also
Hungarian Forint.
Type
const string
See also
Indonesian Rupiah.
Type
const string
See also
Israeli New Shekel.
Type
const string
See also
Indian rupee.
Type
const string
See also
Icelandic Krona.
Type
const string
See also
Japanese yen.
Type
const string
See also
Kenyan Shilling.
Type
const string
See also
South Korean won.
Type
const string
See also
Kuwaiti Dinar.
Type
const string
See also
Sri Lankan Rupee.
Type
const string
See also
Moroccan Dirham.
Type
const string
See also
Mexican Peso.
Type
const string
See also
Malaysian ringgit.
Type
const string
See also
Nigerian Naira.
Type
const string
See also
Norwegian krone.
Type
const string
See also
Unspecified currency.
Type
const string
See also
New Zealand dollar.
Type
const string
See also
Peruvian sol.
Type
const string
See also
Philippine Peso.
Type
const string
See also
Pakistani rupee.
Type
const string
See also
Polish zloty.
Type
const string
See also
Qatari Riyal.
Type
const string
See also
Romanian Leu.
Type
const string
See also
Serbian Dinar.
Type
const string
See also
Russian ruble.
Type
const string
See also
Saudi Riyal.
Type
const string
See also
Swedish krona.
Type
const string
See also
Singapore dollar.
Type
const string
See also
Thai Baht.
Type
const string
See also
Tunisian Dinar.
Type
const string
See also
Turkish lira.
Type
const string
See also
New Taiwan Dollar.
Type
const string
See also
United States dollar.
Type
const string
See also
Tether.
Type
const string
See also
Venezuelan Bolivar.
Type
const string
See also
Vietnamese Dong.
Type
const string
See also
South African rand.
Type
const string
See also
Is a named constant for return value of dayofweek() function and value of dayofweek variable.
Type
const int
See also
dayofweek.sundaydayofweek.mondaydayofweek.tuesdaydayofweek.wednesdaydayofweek.thursdaydayofweek.saturday
Is a named constant for return value of dayofweek() function and value of dayofweek variable.
Type
const int
See also
dayofweek.sundaydayofweek.tuesdaydayofweek.wednesdaydayofweek.thursdaydayofweek.fridaydayofweek.saturday
Is a named constant for return value of dayofweek() function and value of dayofweek variable.
Type
const int
See also
dayofweek.sundaydayofweek.mondaydayofweek.tuesdaydayofweek.wednesdaydayofweek.thursdaydayofweek.friday
Is a named constant for return value of dayofweek() function and value of dayofweek variable.
Type
const int
See also
dayofweek.mondaydayofweek.tuesdaydayofweek.wednesdaydayofweek.thursdaydayofweek.fridaydayofweek.saturday
Is a named constant for return value of dayofweek() function and value of dayofweek variable.
Type
const int
See also
dayofweek.sundaydayofweek.mondaydayofweek.tuesdaydayofweek.wednesdaydayofweek.fridaydayofweek.saturday
Is a named constant for return value of dayofweek() function and value of dayofweek variable.
Type
const int
See also
dayofweek.sundaydayofweek.mondaydayofweek.wednesdaydayofweek.thursdaydayofweek.fridaydayofweek.saturday
Is a named constant for return value of dayofweek() function and value of dayofweek variable.
Type
const int
See also
dayofweek.sundaydayofweek.mondaydayofweek.tuesdaydayofweek.thursdaydayofweek.fridaydayofweek.saturday
A named constant for use with the display parameter of the plot*(), input*(), fill(), bgcolor(), barcolor(), and hline() functions. Specifies that the values or visuals appear in all possible locations by default.
Type
const plot_simple_display
Remarks
The display.* constants support + and - operations, enabling custom combinations of display settings. For example, display.all - display.data_window specifies that the data for an input or plot appears in all possible locations except for the Data Window.
Selecting a deselected plot in the script's "Settings/Style" tab changes its display settings, causing the plotted data to appear in all available chart locations. To restore the display settings coded in the script, select "Reset settings" from the "Defaults" dropdown menu at the bottom of the "Settings" dialog box.
See also
plot()plotshape()plotchar()plotarrow()plotbar()plotcandle()
A named constant for use with the display parameter of the plot*() and input*() functions. Specifies that the values are available in the Data Window by default. The Data Window tab is accessible by clicking the "Object Tree and Data Window" icon in the chart's right sidebar.
Type
const plot_display
Remarks
The display.* constants support + and - operations, enabling custom combinations of display settings. For example, display.data_window + display.status_line specifies that the data for an input or plot appears in the Data Window and the script's status line, and display.all - display.data_window specifies that the data appears in all possible locations except for the Data Window.
Selecting a deselected plot in the script's "Settings/Style" tab changes its display settings, causing the plotted data to appear in all available chart locations. To restore the display settings coded in the script, select "Reset settings" from the "Defaults" dropdown menu at the bottom of the "Settings" dialog box.
See also
plot()plotshape()plotchar()plotarrow()plotbar()plotcandle()
A named constant for use with the display parameter of the plot*(), input*(), fill(), bgcolor(), barcolor(), and hline() functions. Specifies that the values or visuals are not displayed anywhere by default.
Type
const plot_simple_display
Remarks
Selecting a deselected plot in the script's "Settings/Style" tab changes its display settings, causing the plotted data to appear in all available chart locations. To restore the display settings coded in the script, select "Reset settings" from the "Defaults" dropdown menu at the bottom of the "Settings" dialog box.
See also
plot()plotshape()plotchar()plotarrow()plotbar()plotcandle()
A named constant for use with the display parameter of the plot*() functions. Specifies that the plotted values are displayed in a chart pane by default.
Type
const plot_display
Remarks
The display.* constants support + and - operations, enabling custom combinations of display settings. For example, display.pane + display.data_window specifies that the plot's values appear in the chart pane and the Data Window, and display.all - display.pane specifies that the values appear in all possible locations except for the chart pane.
Selecting a deselected plot in the script's "Settings/Style" tab changes its display settings, causing the plotted data to appear in all available chart locations. To restore the display settings coded in the script, select "Reset settings" from the "Defaults" dropdown menu at the bottom of the "Settings" dialog box.
See also
plot()plotshape()plotchar()plotarrow()plotbar()plotcandle()
A named constant for use with the display parameter of the plot() function. Specifies that, by default, the Pine Screener displays a column for the plot's values when the user applies the indicator to the chosen watchlist.
Type
const plot_display
Remarks
The display.* constants support + and - operations, enabling custom combinations of display settings. For example, display.data_window + display.pine_screener specifies that the plotted values appear in the Data Window and the Pine Screener, and display.all - display.pine_screener specifies that the values appear in all possible locations except for the Pine Screener.
The Pine Screener displays columns for only the first 10 enabled plots from a script by default. If a plot's default display settings do not include the screener, or if the screener already shows columns for 10 other plots from the script, users can configure the screener to show a column for the plot by using the "Manage columns" menu at the far right of the table header.
See also
plot()plotshape()plotchar()plotarrow()plotbar()plotcandle()
A named constant for use with the display parameter of the plot*() functions. Specifies that the price scale displays a label for the plot's data, but only if the chart's settings allow it.
Type
const plot_display
Remarks
The display.* constants support + and - operations, enabling custom combinations of display settings. For example, display.price_scale + display.data_window specifies that the plot's data appears on the price scale and in the Data Window, and display.all - display.price_scale specifies that the data appears in all possible locations except for the price scale.
Selecting a deselected plot in the script's "Settings/Style" tab changes its display settings, causing the plotted data to appear in all available chart locations. To restore the display settings coded in the script, select "Reset settings" from the "Defaults" dropdown menu at the bottom of the "Settings" dialog box.
See also
plot()plotshape()plotchar()plotarrow()plotbar()plotcandle()
A named constant for use with the display parameter of the plot*() and input*() functions. Specifies that the values are available in the script's status line, but only if the chart's settings allow it.
Type
const plot_display
Remarks
The display.* constants support + and - operations, enabling custom combinations of display settings. For example, display.data_window + display.status_line specifies that the data for an input or plot appears in the Data Window and the script's status line, and display.all - display.status_line specifies that the data appears in all possible locations except for the status line.
Selecting a deselected plot in the script's "Settings/Style" tab changes its display settings, causing the plotted data to appear in all available chart locations. To restore the display settings coded in the script, select "Reset settings" from the "Defaults" dropdown menu at the bottom of the "Settings" dialog box.
See also
plot()plotshape()plotchar()plotarrow()plotbar()plotcandle()
A named constant for the request.dividends() function. Is used to request the dividends return on a stock before deductions.
Type
const string
See also
A named constant for the request.dividends() function. Is used to request the dividends return on a stock after deductions.
Type
const string
See also
A named constant for the request.earnings() function. Is used to request the earnings value as it was reported.
Type
const string
See also
A named constant for the request.earnings() function. Is used to request the estimated earnings value.
Type
const string
See also
A named constant for the request.earnings() function. Is used to request the standardized earnings value.
Type
const string
See also
A named constant for line.new() and line.set_extend() functions.
Type
const string
See also
line.new()line.set_extend()extend.noneextend.leftextend.right
A named constant for line.new() and line.set_extend() functions.
Type
const string
See also
line.new()line.set_extend()extend.noneextend.rightextend.both
A named constant for line.new() and line.set_extend() functions.
Type
const string
See also
line.new()line.set_extend()extend.leftextend.rightextend.both
A named constant for line.new() and line.set_extend() functions.
Type
const string
See also
line.new()line.set_extend()extend.noneextend.leftextend.both
Literal representing a bool value, and result of a comparison operation.
Remarks
See the User Manual for comparison operators and logical operators.
See also
Default text font for box.new(), box.set_text_font_family(), label.new(), label.set_text_font_family(), table.cell() and table.cell_set_text_font_family() functions.
Type
const string
See also
box.new()box.set_text_font_family()label.new()label.set_text_font_family()table.cell()table.cell_set_text_font_family()font.family_monospace
Monospace text font for box.new(), box.set_text_font_family(), label.new(), label.set_text_font_family(), table.cell() and table.cell_set_text_font_family() functions.
Type
const string
See also
box.new()box.set_text_font_family()label.new()label.set_text_font_family()table.cell()table.cell_set_text_font_family()font.family_default
Is a named constant for selecting the formatting of the script output values from the parent series in the indicator() function.
Type
const string
See also
indicator()format.priceformat.volumeformat.percent
Is a named constant to use with the str.tostring() function. Passing a number to str.tostring() with this argument rounds the number to the nearest value that can be divided by syminfo.mintick, without the remainder, with ties rounding up, and returns the string version of said value with trailing zeros.
Type
const string
See also
indicator()format.inheritformat.priceformat.volume
Is a named constant for selecting the formatting of the script output values as a percentage in the indicator function. It adds a percent sign after values.
Type
const string
Remarks
The default precision is 2, regardless of the precision of the chart itself. This can be changed with the 'precision' argument of the indicator() function.
See also
indicator()format.inheritformat.priceformat.volume
Is a named constant for selecting the formatting of the script output values as prices in the indicator() function.
Type
const string
Remarks
If format is format.price, default precision value is set. You can use the precision argument of indicator function to change the precision value.
See also
indicator()format.inheritformat.volumeformat.percent
Is a named constant for selecting the formatting of the script output values as volume in the indicator() function, e.g. '5183' will be formatted as '5.183K'.
The decimal precision rules defined by this variable take precedence over other precision settings. When an indicator(), strategy(), or plot*() call uses this format option, the function's precision parameter will not affect the result.
Type
const string
See also
indicator()format.inheritformat.priceformat.percent
Is a named constant for dashed linestyle of hline() function.
Type
const hline_style
See also
hline.style_solidhline.style_dotted
Is a named constant for dotted linestyle of hline() function.
Type
const hline_style
See also
hline.style_solidhline.style_dashed
Is a named constant for solid linestyle of hline() function.
Type
const hline_style
See also
hline.style_dottedhline.style_dashed
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_square
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangleuplabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_xcrosslabel.style_crosslabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_lower_leftlabel.style_label_lower_rightlabel.style_label_upper_leftlabel.style_label_upper_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Label style for label.new() and label.set_style() functions.
Type
const string
See also
label.new()label.set_style()label.set_textalign()label.style_nonelabel.style_crosslabel.style_triangleuplabel.style_triangledownlabel.style_flaglabel.style_circlelabel.style_arrowuplabel.style_arrowdownlabel.style_label_uplabel.style_label_downlabel.style_label_leftlabel.style_label_rightlabel.style_label_centerlabel.style_squarelabel.style_diamond
Line style for line.new() and line.set_style() functions. Solid line with arrows on both points.
Type
const string
See also
line.new()line.set_style()line.style_solidline.style_dottedline.style_dashedline.style_arrow_leftline.style_arrow_right
Line style for line.new() and line.set_style() functions. Solid line with arrow on the first point.
Type
const string
See also
line.new()line.set_style()line.style_solidline.style_dottedline.style_dashedline.style_arrow_rightline.style_arrow_both
Line style for line.new() and line.set_style() functions. Solid line with arrow on the second point.
Type
const string
See also
line.new()line.set_style()line.style_solidline.style_dottedline.style_dashedline.style_arrow_leftline.style_arrow_both
Line style for line.new() and line.set_style() functions.
Type
const string
See also
line.new()line.set_style()line.style_solidline.style_dottedline.style_arrow_leftline.style_arrow_rightline.style_arrow_both
Line style for line.new() and line.set_style() functions.
Type
const string
See also
line.new()line.set_style()line.style_solidline.style_dashedline.style_arrow_leftline.style_arrow_rightline.style_arrow_both
Line style for line.new() and line.set_style() functions.
Type
const string
See also
line.new()line.set_style()line.style_dottedline.style_dashedline.style_arrow_leftline.style_arrow_rightline.style_arrow_both
Location value for plotshape(), plotchar() functions. Shape is plotted above main series bars.
Type
const string
See also
plotshape()plotchar()location.belowbarlocation.toplocation.bottomlocation.absolute
Location value for plotshape(), plotchar() functions. Shape is plotted on chart using indicator value as a price coordinate.
Type
const string
See also
plotshape()plotchar()location.abovebarlocation.belowbarlocation.toplocation.bottom
Location value for plotshape(), plotchar() functions. Shape is plotted below main series bars.
Type
const string
See also
plotshape()plotchar()location.abovebarlocation.toplocation.bottomlocation.absolute
Location value for plotshape(), plotchar() functions. Shape is plotted near the bottom chart border.
Type
const string
See also
plotshape()plotchar()location.abovebarlocation.belowbarlocation.toplocation.absolute
Location value for plotshape(), plotchar() functions. Shape is plotted near the top chart border.
Type
const string
See also
plotshape()plotchar()location.abovebarlocation.belowbarlocation.bottomlocation.absolute
Is a named constant for Euler's number. It is equal to 2.7182818284590452.
Type
const float
See also
Is a named constant for the golden ratio. It is equal to 1.6180339887498948.
Type
const float
See also
Is a named constant for Archimedes' constant. It is equal to 3.1415926535897932.
Type
const float
See also
Is a named constant for the golden ratio conjugate. It is equal to 0.6180339887498948.
Type
const float
See also
Determines the sort order of the array from the smallest to the largest value.
Type
const sort_order
See also
Determines the sort order of the array from the largest to the smallest value.
Type
const sort_order
See also
A named constant for use with the plot() function's linestyle parameter, which modifies the appearance of plotted lines. If the style argument of the function call specifies a plot style that displays a line, using this constant as the linestyle argument specifies that the plotted line is dashed.
Type
const plot_line_style
See also
plot()plot.linestyle_solidplot.linestyle_dotted
A named constant for use with the plot() function's linestyle parameter, which modifies the appearance of plotted lines. If the style argument of the function call specifies a plot style that displays a line, using this constant as the linestyle argument specifies that the plotted line is dotted.
Type
const plot_line_style
See also
plot()plot.linestyle_dashedplot.linestyle_solid
A named constant for use with the plot() function's linestyle parameter, which modifies the appearance of plotted lines. If the style argument of the function call specifies a plot style that displays a line, using this constant as the linestyle argument specifies that the plotted line is solid.
Type
const plot_line_style
See also
plot()plot.linestyle_dashedplot.linestyle_dotted
A named constant for the 'Area' style, to be used as an argument for the style parameter in the plot() function.
Type
const plot_style
See also
plot()plot.style_lineplot.style_linebrplot.style_histogramplot.style_crossplot.style_areabrplot.style_columnsplot.style_circlesplot.style_steplineplot.style_stepline_diamondplot.style_steplinebr
A named constant for the 'Area With Breaks' style, to be used as an argument for the style parameter in the plot() function. Similar to plot.style_area, except the gaps in the data are not filled.
Type
const plot_style
See also
plot()plot.style_lineplot.style_linebrplot.style_histogramplot.style_crossplot.style_areaplot.style_columnsplot.style_circlesplot.style_steplineplot.style_stepline_diamondplot.style_steplinebr
A named constant for the 'Circles' style, to be used as an argument for the style parameter in the plot() function.
Type
const plot_style
See also
plot()plot.style_lineplot.style_linebrplot.style_histogramplot.style_crossplot.style_areaplot.style_areabrplot.style_columnsplot.style_steplineplot.style_stepline_diamondplot.style_steplinebr
A named constant for the 'Columns' style, to be used as an argument for the style parameter in the plot() function.
Type
const plot_style
See also
plot()plot.style_lineplot.style_linebrplot.style_histogramplot.style_crossplot.style_areaplot.style_areabrplot.style_circlesplot.style_steplineplot.style_stepline_diamondplot.style_steplinebr
A named constant for the 'Cross' style, to be used as an argument for the style parameter in the plot() function.
Type
const plot_style
See also
plot()plot.style_lineplot.style_linebrplot.style_histogramplot.style_areaplot.style_areabrplot.style_columnsplot.style_circlesplot.style_steplineplot.style_stepline_diamondplot.style_steplinebr
A named constant for the 'Histogram' style, to be used as an argument for the style parameter in the plot() function.
Type
const plot_style
See also
plot()plot.style_lineplot.style_linebrplot.style_crossplot.style_areaplot.style_areabrplot.style_columnsplot.style_circlesplot.style_steplineplot.style_stepline_diamondplot.style_steplinebr
A named constant for the 'Line' style, to be used as an argument for the style parameter in the plot() function.
Type
const plot_style
See also
plot()plot.style_linebrplot.style_histogramplot.style_crossplot.style_areaplot.style_areabrplot.style_columnsplot.style_circlesplot.style_steplineplot.style_stepline_diamondplot.style_steplinebr
A named constant for the 'Line With Breaks' style, to be used as an argument for the style parameter in the plot() function. Similar to plot.style_line, except the gaps in the data are not filled.
Type
const plot_style
See also
plot()plot.style_lineplot.style_histogramplot.style_crossplot.style_areaplot.style_areabrplot.style_columnsplot.style_circlesplot.style_steplineplot.style_stepline_diamondplot.style_steplinebr
A named constant for the 'Step Line' style, to be used as an argument for the style parameter in the plot() function.
Type
const plot_style
See also
plot()plot.style_lineplot.style_linebrplot.style_histogramplot.style_crossplot.style_areaplot.style_areabrplot.style_columnsplot.style_circlesplot.style_stepline_diamondplot.style_steplinebr
A named constant for the 'Step Line With Diamonds' style, to be used as an argument for the style parameter in the plot() function. Similar to plot.style_stepline, except the data changes are also marked with the Diamond shapes.
Type
const plot_style
See also
plot()plot.style_lineplot.style_linebrplot.style_histogramplot.style_crossplot.style_areaplot.style_areabrplot.style_columnsplot.style_circlesplot.style_steplineplot.style_steplinebr
A named constant for the 'Step line with Breaks' style, to be used as an argument for the style parameter in the plot() function.
Type
const plot_style
See also
plot()plot.style_lineplot.style_linebrplot.style_histogramplot.style_crossplot.style_areaplot.style_areabrplot.style_columnsplot.style_circlesplot.style_steplineplot.style_stepline_diamond
Table position is used in table.new(), table.cell() functions.
Binds the table to the bottom edge in the center.
Type
const string
See also
table.new()table.cell()table.set_position()position.top_leftposition.top_centerposition.top_rightposition.middle_leftposition.middle_centerposition.middle_rightposition.bottom_leftposition.bottom_right
Table position is used in table.new(), table.cell() functions.
Binds the table to the bottom left of the screen.
Type
const string
See also
table.new()table.cell()table.set_position()position.top_leftposition.top_centerposition.top_rightposition.middle_leftposition.middle_centerposition.middle_rightposition.bottom_centerposition.bottom_right
Table position is used in table.new(), table.cell() functions.
Binds the table to the bottom right of the screen.
Type
const string
See also
table.new()table.cell()table.set_position()position.top_leftposition.top_centerposition.top_rightposition.middle_leftposition.middle_centerposition.middle_rightposition.bottom_leftposition.bottom_center
Table position is used in table.new(), table.cell() functions.
Binds the table to the center of the screen.
Type
const string
See also
table.new()table.cell()table.set_position()position.top_leftposition.top_centerposition.top_rightposition.middle_leftposition.middle_rightposition.bottom_leftposition.bottom_centerposition.bottom_right
Table position is used in table.new(), table.cell() functions.
Binds the table to the left side of the screen.
Type
const string
See also
table.new()table.cell()table.set_position()position.top_leftposition.top_centerposition.top_rightposition.middle_centerposition.middle_rightposition.bottom_leftposition.bottom_centerposition.bottom_right
Table position is used in table.new(), table.cell() functions.
Binds the table to the right side of the screen.
Type
const string
See also
table.new()table.cell()table.set_position()position.top_leftposition.top_centerposition.top_rightposition.middle_leftposition.middle_centerposition.bottom_leftposition.bottom_centerposition.bottom_right
Table position is used in table.new(), table.cell() functions.
Binds the table to the top edge in the center.
Type
const string
See also
table.new()table.cell()table.set_position()position.top_leftposition.top_rightposition.middle_leftposition.middle_centerposition.middle_rightposition.bottom_leftposition.bottom_centerposition.bottom_right
Table position is used in table.new(), table.cell() functions.
Binds the table to the upper-left edge.
Type
const string
See also
table.new()table.cell()table.set_position()position.top_centerposition.top_rightposition.middle_leftposition.middle_centerposition.middle_rightposition.bottom_leftposition.bottom_centerposition.bottom_right
Table position is used in table.new(), table.cell() functions.
Binds the table to the upper-right edge.
Type
const string
See also
table.new()table.cell()table.set_position()position.top_leftposition.top_centerposition.middle_leftposition.middle_centerposition.middle_rightposition.bottom_leftposition.bottom_centerposition.bottom_right
A named constant for use as the scale argument in indicator() and strategy() declaration statements. Specifies that the script's price scale is on the left side of the pane. If the script overlays on the main chart pane or another script's pane, it adds a new price scale on the left side of the pane and scales its visuals independently to fit the pane's visual space.
Type
const scale_type
See also
A named constant for use as the scale argument in indicator() and strategy() declaration statements. A declaration statement can use this constant only if its overlay argument is true. Specifies that the script scales its visuals independently to fit the visual space of the main chart pane or another script's pane without displaying a separate scale. The script displays plotted numbers directly on the pane's existing price scale if the chart's settings allow it. If the user moves the script to a new pane, the script displays the values on a new scale to the left or right of that pane, depending on the chart's "Scales placement" setting.
Type
const scale_type
See also
A named constant for use as the scale argument in indicator() and strategy() declaration statements. Specifies that the script's price scale is on the right side of the pane. If the script overlays on the main chart pane or another script's pane, it adds a new price scale on the right side of the pane and scales its visuals independently to fit the pane's visual space.
Type
const scale_type
See also
Constant for extended session type (with extended hours data).
Type
const string
See also
session.regularsyminfo.session
Constant for regular session type (no extended hours data).
Type
const string
See also
session.extendedsyminfo.session
A constant to specify the value of the settlement_as_close parameter in ticker.new() and ticker.modify() functions.
Type
const settlement
See also
ticker.new()ticker.modify()settlement_as_close.onsettlement_as_close.off
A constant to specify the value of the settlement_as_close parameter in ticker.new() and ticker.modify() functions.
Type
const settlement
See also
ticker.new()ticker.modify()settlement_as_close.onsettlement_as_close.inherit
A constant to specify the value of the settlement_as_close parameter in ticker.new() and ticker.modify() functions.
Type
const settlement
See also
ticker.new()ticker.modify()settlement_as_close.inheritsettlement_as_close.off
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
Shape style for plotshape() function.
Type
const string
See also
A constant to specify the size of the graphics drawn by plotchar(), plotshape(), label.new(), and box.new(). Adjusts the size of the graphics automatically.
Type
const string
See also
plotshape()plotchar()label.set_size()size.tinysize.smallsize.normalsize.largesize.huge
A constant to specify the size of the graphics drawn by plotchar(), plotshape(), label.new(), box.new(), and table.cell(). Sets the size to huge.
Type
const string
See also
plotshape()plotchar()label.set_size()size.autosize.tinysize.smallsize.normalsize.large
A constant to specify the size of the graphics drawn by plotchar(), plotshape(), label.new(), box.new(), and table.cell(). Sets the size to large.
Type
const string
See also
plotshape()plotchar()label.set_size()size.autosize.tinysize.smallsize.normalsize.huge
A constant to specify the size of the graphics drawn by plotchar(), plotshape(), label.new(), box.new(), and table.cell(). Sets the size to normal.
Type
const string
See also
plotshape()plotchar()label.set_size()size.autosize.tinysize.smallsize.largesize.huge
A constant to specify the size of the graphics drawn by plotchar(), plotshape(), label.new(), box.new(), and table.cell(). Sets the size to small.
Type
const string
See also
plotshape()plotchar()label.set_size()size.autosize.tinysize.normalsize.largesize.huge
A constant to specify the size of the graphics drawn by plotchar(), plotshape(), label.new(), box.new(), and table.cell(). Sets the size to tiny.
Type
const string
See also
plotshape()plotchar()label.set_size()size.autosize.smallsize.normalsize.largesize.huge
A named constant for the request.splits() function. Is used to request the denominator (the number below the line in a fraction) of a splits.
Type
const string
See also
A named constant for the request.splits() function. Is used to request the numerator (the number above the line in a fraction) of a splits.
Type
const string
See also
This is one of the arguments that can be supplied to the default_qty_type parameter in the strategy() declaration statement. It is only relevant when no value is used for the ‘qty’ parameter in strategy.entry() or strategy.order() function calls. It specifies that an amount of cash in the strategy.account_currency will be used to enter trades.
Type
const string
Example
//@version=6strategy("strategy.cash", overlay = true, default_qty_value = 50, default_qty_type = strategy.cash, initial_capital = 1000000)if bar_index == 0 // As ‘qty’ is not defined, the previously defined values for the `default_qty_type` and `default_qty_value` parameters are used to enter trades, namely 50 units of cash in the currency of `strategy.account_currency`. // `qty` is calculated as (default_qty_value)/(close price). If current price is $5, then qty = 50/5 = 10. strategy.entry("EN", strategy.long)if bar_index == 2 strategy.close("EN")
See also
Commission type for an order. Money displayed in the account currency per contract.
Type
const string
See also
Commission type for an order. Money displayed in the account currency per order.
Type
const string
See also
Commission type for an order. A percentage of the cash volume of order.
Type
const string
See also
It allows strategy to open both long and short positions.
Type
const string
See also
strategy.risk.allow_entry_in()
It allows strategy to open only long positions.
Type
const string
See also
strategy.risk.allow_entry_in()
It allows strategy to open only short positions.
Type
const string
See also
strategy.risk.allow_entry_in()
This is one of the arguments that can be supplied to the default_qty_type parameter in the strategy() declaration statement. It is only relevant when no value is used for the ‘qty’ parameter in strategy.entry() or strategy.order() function calls. It specifies that a number of contracts/shares/lots will be used to enter trades.
Type
const string
Example
//@version=6strategy("strategy.fixed", overlay = true, default_qty_value = 50, default_qty_type = strategy.fixed, initial_capital = 1000000)if bar_index == 0 // As ‘qty’ is not defined, the previously defined values for the `default_qty_type` and `default_qty_value` parameters are used to enter trades, namely 50 contracts. // qty = 50 strategy.entry("EN", strategy.long)if bar_index == 2 strategy.close("EN")
See also
A named constant for use with the direction parameter of the strategy.entry() and strategy.order() commands. It specifies that the command creates a buy order.
Type
const strategy_direction
See also
strategy.entry()strategy.exit()strategy.order()
A named constant for use with the oca_type parameter of the strategy.entry() and strategy.order() commands. It specifies that the strategy cancels the unfilled order when another order with the same oca_name and oca_type executes.
Type
const string
Remarks
Strategies cannot cancel or reduce pending orders from an OCA group if they execute on the same tick. For example, if the market price triggers two stop orders from strategy.order() calls with the same oca_* arguments, the strategy cannot fully or partially cancel either one.
See also
strategy.entry()strategy.exit()strategy.order()
A named constant for use with the oca_type parameter of the strategy.entry() and strategy.order() commands. It specifies that the order executes independently of all other orders, including those with the same oca_name.
Type
const string
See also
strategy.entry()strategy.exit()strategy.order()
A named constant for use with the oca_type parameter of the strategy.entry() and strategy.order() commands. It specifies that when another order with the same oca_name and oca_type executes, the strategy reduces the unfilled order by that order's size. If the unfilled order's size reaches 0 after reduction, it is the same as canceling the order entirely.
Type
const string
Remarks
Strategies cannot cancel or reduce pending orders from an OCA group if they execute on the same tick. For example, if the market price triggers two stop orders from strategy.order() calls with the same oca_* arguments, the strategy cannot fully or partially cancel either one.
Orders from strategy.exit() automatically use this OCA type, and they belong to the same OCA group by default.
See also
strategy.entry()strategy.exit()strategy.order()
This is one of the arguments that can be supplied to the default_qty_type parameter in the strategy() declaration statement. It is only relevant when no value is used for the ‘qty’ parameter in strategy.entry() or strategy.order() function calls. It specifies that a percentage (0-100) of equity will be used to enter trades.
Type
const string
Example
//@version=6strategy("strategy.percent_of_equity", overlay = false, default_qty_value = 100, default_qty_type = strategy.percent_of_equity, initial_capital = 1000000)// As ‘qty’ is not defined, the previously defined values for the `default_qty_type` and `default_qty_value` parameters are used to enter trades, namely 100% of available equity.if bar_index == 0 strategy.entry("EN", strategy.long)if bar_index == 2 strategy.close("EN")plot(strategy.equity) // The ‘qty’ parameter is set to 10. Entering position with fixed size of 10 contracts and entry market price = (10 * close).if bar_index == 4 strategy.entry("EN", strategy.long, qty = 10)if bar_index == 6 strategy.close("EN")
See also
A named constant for use with the direction parameter of the strategy.entry() and strategy.order() commands. It specifies that the command creates a sell order.
Type
const strategy_direction
See also
strategy.entry()strategy.exit()strategy.order()
Vertical text alignment for box.new(), box.set_text_valign(), table.cell() and table.cell_set_text_valign() functions.
Type
const string
See also
table.cell()table.cell_set_text_valign()text.align_centertext.align_lefttext.align_right
Text alignment for box.new(), box.set_text_halign(), box.set_text_valign(), label.new() and label.set_textalign() functions.
Type
const string
See also
label.new()label.set_style()text.align_lefttext.align_right
Horizontal text alignment for box.new(), box.set_text_halign(), label.new() and label.set_textalign() functions.
Type
const string
See also
label.new()label.set_style()text.align_centertext.align_right
Horizontal text alignment for box.new(), box.set_text_halign(), label.new() and label.set_textalign() functions.
Type
const string
See also
label.new()label.set_style()text.align_centertext.align_left
Vertical text alignment for box.new(), box.set_text_valign(), table.cell() and table.cell_set_text_valign() functions.
Type
const string
See also
table.cell()table.cell_set_text_valign()text.align_centertext.align_lefttext.align_right
A named constant for use with the text_formatting parameter of the label.new(), box.new(), table.cell(), and *set_text_formatting() functions. Makes the text bold.
Type
const text_format
See also
label.new()box.new()table.cell()
A named constant for use with the text_formatting parameter of the label.new(), box.new(), table.cell(), and *set_text_formatting() functions. Italicizes the text.
Type
const text_format
See also
label.new()box.new()table.cell()
A named constant for use with the text_formatting parameter of the label.new(), box.new(), table.cell(), and *set_text_formatting() functions. Signifies no special text formatting.
Type
const text_format
See also
label.new()box.new()table.cell()
Automatic wrapping mode for box.new() and box.set_text_wrap() functions.
Type
const string
See also
box.new()box.set_text()box.set_text_wrap()
Disabled wrapping mode for box.new() and box.set_text_wrap() functions.
Type
const string
See also
box.new()box.set_text()box.set_text_wrap()
Literal representing one of the values a bool variable can hold, or an expression can evaluate to when it uses comparison or logical operators.
Remarks
See the User Manual for comparison operators and logical operators.
See also
A constant that specifies how functions that create and modify Pine drawings interpret x-coordinates. If xloc = xloc.bar_index, the drawing object treats each x-coordinate as a bar_index value.
Type
const string
See also
xloc.bar_timeline.new()label.new()box.new()polyline.new()line.set_xloc()label.set_xloc()
A constant that specifies how functions that create and modify Pine drawings interpret x-coordinates. If xloc = xloc.bar_time, the drawing object treats each x-coordinate as a UNIX timestamp, expressed in milliseconds.
Type
const string
See also
xloc.bar_indexline.new()label.new()box.new()polyline.new()line.set_xloc()label.set_xloc()xloc.bar_index
A named constant that specifies the algorithm of interpretation of y-value in function label.new().
Type
const string
See also
label.new()label.set_yloc()yloc.priceyloc.belowbar
A named constant that specifies the algorithm of interpretation of y-value in function label.new().
Type
const string
See also
label.new()label.set_yloc()yloc.priceyloc.abovebar
A named constant that specifies the algorithm of interpretation of y-value in function label.new().
Type
const string
See also