TradingChart
✖
TradingChart
makes a chart showing prices and volume for each date.
makes a financial chart for the financial entity "name" over the daterange.
Details and Options




- TradingChart by default includes a candlestick chart and a volume indicator.
- The dates datei are considered an ordered sequence of events, and are not shown on an absolute time scale. The date formats for datei are the same as used in DateListPlot.
- The "name" and daterange are the same as used in FinancialData.
- The indicators indi can be any FinancialIndicator object.
- Wrappers can be applied to indicators using the form w[indi].
- Wrappers can be applied to the entire dataset using the form w[{{date1,ohlcv1},…}] or w[{"name",daterange}].
- TradingChart[Tabular[…]cspec] extracts and plots values from the tabular object using the column specification cspec.
- The following forms of column specifications cspec are allowed for plotting tabular data:
-
{coldate,{colopen,colhigh,collow,colclose,colvol}} plot values from columns {colopen,…,colvol} against dates from coldate - The following wrappers can be used:
-
Annotation[data,label] provide an annotation Button[data,action] define an action to execute when the element is clicked EventHandler[data,…] define a general event handler for the element Hyperlink[data,uri] make the element act as a hyperlink PopupWindow[data,cont] attach a popup window to the element StatusArea[data,label] display in the status area when the element is moused over Style[data,opts] show the element using the specified styles Tooltip[data,label] attach an arbitrary tooltip to the element - TradingChart has the same options as Graphics with the following additions and changes: [List of all options]
-
Appearance "Candlestick" appearance to use AspectRatio 1/GoldenRatio overall ratio of width to height Axes True whether to draw axes BarSpacing Automatic spacing between candles ChartBaseStyle Automatic overall style for bars ChartElementFunction Automatic how to generate raw graphics for candlesticks ColorFunction Automatic how to color candles ColorFunctionScaling True whether to normalize arguments to ColorFunction DateFunction Automatic how to convert dates to standard form EventLabels None events to label GridLines Automatic grid lines to draw GridLinesStyle Automatic style for grid lines PerformanceGoal $PerformanceGoal aspects of performance to try to optimize PlotTheme $PlotTheme overall theme for the chart TargetUnits Automatic units to display in the chart TrendStyle Automatic how to style up and down trends ScalingFunctions None how to scale the axis
- Possible settings for Appearance include: "Candlestick", "OHLC", "Line", and None.
- The arguments supplied to ChartElementFunction are the box region {{xmin,xmax},{ymin,ymax}}, {datei,{oi,hi,li,ci}}, and metadata {m1,m2,…}.
- A list of built-in settings for ChartElementFunction can be obtained from ChartElementData["TradingChart"].
- The arguments supplied to ColorFunction are date,open,high,low,close,volume,close-open.
- With ScalingFunctions->sy, the function sy is applied to all prices (open, high, low, close). ScalingFunctions only affect the display and none of the controls.
- Style and other specifications from options and other constructs in TradingChart are effectively applied in the order TrendStyle, ColorFunction, Style and other wrappers, and ChartElementFunction, with later specifications overriding earlier ones.
-
AlignmentPoint Center the default point in the graphic to align with Appearance "Candlestick" appearance to use AspectRatio 1/GoldenRatio overall ratio of width to height Axes True whether to draw axes AxesLabel None axes labels AxesOrigin Automatic where axes should cross AxesStyle {} style specifications for the axes Background None background color for the plot BarSpacing Automatic spacing between candles BaselinePosition Automatic how to align with a surrounding text baseline BaseStyle {} base style specifications for the graphic ChartBaseStyle Automatic overall style for bars ChartElementFunction Automatic how to generate raw graphics for candlesticks ColorFunction Automatic how to color candles ColorFunctionScaling True whether to normalize arguments to ColorFunction ContentSelectable Automatic whether to allow contents to be selected CoordinatesToolOptions Automatic detailed behavior of the coordinates tool DateFunction Automatic how to convert dates to standard form Epilog {} primitives rendered after the main plot EventLabels None events to label FormatType TraditionalForm the default format type for text Frame False whether to put a frame around the plot FrameLabel None frame labels FrameStyle {} style specifications for the frame FrameTicks Automatic frame ticks FrameTicksStyle {} style specifications for frame ticks GridLines Automatic grid lines to draw GridLinesStyle Automatic style for grid lines ImageMargins 0. the margins to leave around the graphic ImagePadding All what extra padding to allow for labels etc. ImageSize Automatic the absolute size at which to render the graphic LabelStyle {} style specifications for labels Method Automatic details of graphics methods to use PerformanceGoal $PerformanceGoal aspects of performance to try to optimize PlotLabel None an overall label for the plot PlotRange All range of values to include PlotRangeClipping False whether to clip at the plot range PlotRangePadding Automatic how much to pad the range of values PlotRegion Automatic the final display region to be filled PlotTheme $PlotTheme overall theme for the chart PreserveImageOptions Automatic whether to preserve image options when displaying new versions of the same graphic Prolog {} primitives rendered before the main plot RotateLabel True whether to rotate y labels on the frame ScalingFunctions None how to scale the axis
TargetUnits Automatic units to display in the chart Ticks Automatic axes ticks TicksStyle {} style specifications for axes ticks TrendStyle Automatic how to style up and down trends
List of all options




Examples
open allclose allBasic Examples (4)Summary of the most common use cases
Chart the prices from a list of values:

https://wolfram.com/xid/09bnnlsrj-es2kpv

https://wolfram.com/xid/09bnnlsrj-43qclg

Use three months of prices from FinancialData entities:

https://wolfram.com/xid/09bnnlsrj-v6a446

Specify a date range for FinancialData entities:

https://wolfram.com/xid/09bnnlsrj-ihy19z

Show a chart with financial indicators:

https://wolfram.com/xid/09bnnlsrj-5lno1c

Scope (26)Survey of the scope of standard use cases
Data and Wrappers (9)
Automatically get quarterly data from today:

https://wolfram.com/xid/09bnnlsrj-nd5ltg

Get data from a specific date range:

https://wolfram.com/xid/09bnnlsrj-jzb4ju

Get data from FinancialData:

https://wolfram.com/xid/09bnnlsrj-8gjf34

https://wolfram.com/xid/09bnnlsrj-3byey3

Use wrappers on individual data:

https://wolfram.com/xid/09bnnlsrj-j5yjxj

Use wrappers on entire datasets:

https://wolfram.com/xid/09bnnlsrj-yhfff1


https://wolfram.com/xid/09bnnlsrj-d78b5k

Override the default tooltips:

https://wolfram.com/xid/09bnnlsrj-dw7akx

Use PopupWindow to provide additional drilldown information:

https://wolfram.com/xid/09bnnlsrj-67ht4l

Button can be used to trigger any action:

https://wolfram.com/xid/09bnnlsrj-hf47e2

Tabular Data (1)
Indicators (4)
TradingChart automatically includes the volume indicator:

https://wolfram.com/xid/09bnnlsrj-hnhup9


https://wolfram.com/xid/09bnnlsrj-5suecg

Specify how many periods to use for the simple moving average using FinancialIndicator:

https://wolfram.com/xid/09bnnlsrj-3wz41f

Indicators may be shown in the main plot or as an additional plot:

https://wolfram.com/xid/09bnnlsrj-z9gla4

Styling and Appearance (8)
Specify styles for up and down trends:

https://wolfram.com/xid/09bnnlsrj-gduxto


https://wolfram.com/xid/09bnnlsrj-055sqg


https://wolfram.com/xid/09bnnlsrj-moey6a

ChartBaseStyle can be used to set a style for all chart elements:

https://wolfram.com/xid/09bnnlsrj-dkk5kn

Style can be used to override styles:

https://wolfram.com/xid/09bnnlsrj-10tvwz

Use built-in programmatically generated bars:

https://wolfram.com/xid/09bnnlsrj-wvz8c


https://wolfram.com/xid/09bnnlsrj-f2wd4m

Space between candlesticks is automatically adjusted based on the number of data points:

https://wolfram.com/xid/09bnnlsrj-8nacr1

Appearance changes based on the number of data points:

https://wolfram.com/xid/09bnnlsrj-mnj9q0

Use a theme with detailed frame ticks and grid lines:

https://wolfram.com/xid/09bnnlsrj-zay8qf

Use a theme with a high-contrast color scheme and edge-fading rectangles:

https://wolfram.com/xid/09bnnlsrj-hcb53c

Labeling (4)
Use Labeled to add a label to a candlestick:

https://wolfram.com/xid/09bnnlsrj-keu5cx

Use symbolic positions for label placement:

https://wolfram.com/xid/09bnnlsrj-zimdy2


https://wolfram.com/xid/09bnnlsrj-zcv07v


https://wolfram.com/xid/09bnnlsrj-b7vuri


https://wolfram.com/xid/09bnnlsrj-qarzmb

Use Placed to control the positioning of labels, using the same positions as for Labeled:

https://wolfram.com/xid/09bnnlsrj-zsfyyz

Options (49)Common values & functionality for each option
Appearance (3)
TradingChart uses "Candlestick" when there are fewer data points:

https://wolfram.com/xid/09bnnlsrj-1ggsqz

TradingChart uses "OHLC" when there are more data points:

https://wolfram.com/xid/09bnnlsrj-5k34rg

Change the appearance of the chart:

https://wolfram.com/xid/09bnnlsrj-0k0egt

None can be used to show only indicators:

https://wolfram.com/xid/09bnnlsrj-9cqz4a

BarSpacing (4)
Use automatically determined spacing between candlesticks:

https://wolfram.com/xid/09bnnlsrj-qdv5bm


https://wolfram.com/xid/09bnnlsrj-63wzn0


https://wolfram.com/xid/09bnnlsrj-gusmpb

Use explicit spacing between candlesticks:

https://wolfram.com/xid/09bnnlsrj-trv2cb

ChartBaseStyle (5)
Use ChartBaseStyle to style candlesticks:

https://wolfram.com/xid/09bnnlsrj-n1kprv


https://wolfram.com/xid/09bnnlsrj-8gwdmx

ChartBaseStyle combines with TrendStyle:

https://wolfram.com/xid/09bnnlsrj-n0vn46

TrendStyle may override settings for ChartBaseStyle:

https://wolfram.com/xid/09bnnlsrj-7bha5m

Style may override settings for ChartBaseStyle:

https://wolfram.com/xid/09bnnlsrj-njm38a

ChartBaseStyle combines with ColorFunction:

https://wolfram.com/xid/09bnnlsrj-dkbxw0

ChartElementFunction (3)
Get a list of built-in settings for ChartElementFunction:

https://wolfram.com/xid/09bnnlsrj-1li2ro

For detailed settings, use Palettes ▶ ChartElementSchemes:

https://wolfram.com/xid/09bnnlsrj-zltog0


https://wolfram.com/xid/09bnnlsrj-irkveu

Write a custom ChartElementFunction:

https://wolfram.com/xid/09bnnlsrj-blz6oy

https://wolfram.com/xid/09bnnlsrj-03r1e

ColorFunction (4)
Color the candlesticks by scaled date, open, high, low, close, or trend value:

https://wolfram.com/xid/09bnnlsrj-wczbby

Color by the size and direction of price changes:

https://wolfram.com/xid/09bnnlsrj-y50tbi


https://wolfram.com/xid/09bnnlsrj-1cr2c5

ColorFunction overrides styles in TrendStyle:

https://wolfram.com/xid/09bnnlsrj-gi8pkt

ColorFunctionScaling (2)
By default scaled values are used:

https://wolfram.com/xid/09bnnlsrj-6ajicj

Use ColorFunctionScaling->False to get unscaled values:

https://wolfram.com/xid/09bnnlsrj-cbj35i

EventLabels (6)

https://wolfram.com/xid/09bnnlsrj-8j4nyt

Use Placed to control label placement outside the candlestick:

https://wolfram.com/xid/09bnnlsrj-4k3ibi

Use positions inside the candlestick:

https://wolfram.com/xid/09bnnlsrj-c4w03v

Place labels at the open, high, low, and close prices:

https://wolfram.com/xid/09bnnlsrj-7ddgul


https://wolfram.com/xid/09bnnlsrj-8yy742

Use Placed to control label appearance:

https://wolfram.com/xid/09bnnlsrj-bs1877

GridLines (4)
GridLines are used by default:

https://wolfram.com/xid/09bnnlsrj-t74orb


https://wolfram.com/xid/09bnnlsrj-hnli7h


https://wolfram.com/xid/09bnnlsrj-7bxzxe

Place grid lines at month or year boundaries:

https://wolfram.com/xid/09bnnlsrj-co8vfu

Use dotted grid lines for months and red grid lines for years:

https://wolfram.com/xid/09bnnlsrj-7tl1sx

GridLinesStyle (3)
By default GridLinesStyle uses dotted grid lines with emphasized year grid lines:

https://wolfram.com/xid/09bnnlsrj-faxx3d

Use blue grid lines for dates and dotted grid lines for prices:

https://wolfram.com/xid/09bnnlsrj-o6oel

GridLines overrides GridLinesStyle:

https://wolfram.com/xid/09bnnlsrj-8jzlqh

Method (4)
The default mouseover effect is a bouncing ball and axis highlight:

https://wolfram.com/xid/09bnnlsrj-i7ewi1


https://wolfram.com/xid/09bnnlsrj-31gouo


https://wolfram.com/xid/09bnnlsrj-h4hdsb

Style the bouncing ball with "HighlightStyle":

https://wolfram.com/xid/09bnnlsrj-ucbzem


https://wolfram.com/xid/09bnnlsrj-suwtuh


https://wolfram.com/xid/09bnnlsrj-c6qm0t

Specify the height in pixels for the axis highlight:

https://wolfram.com/xid/09bnnlsrj-tyqg3k

PerformanceGoal (3)
Generate a candlestick chart with interactive highlighting:

https://wolfram.com/xid/09bnnlsrj-6j7w7x

Emphasize performance by disabling interactive behaviors:

https://wolfram.com/xid/09bnnlsrj-8hoprn

Typically less memory is required for non-interactive charts:

https://wolfram.com/xid/09bnnlsrj-kpya84

PlotRange (3)
TradingChart automatically draws all price dates:

https://wolfram.com/xid/09bnnlsrj-u9i3bb

Limit to a specific date range:

https://wolfram.com/xid/09bnnlsrj-4abjsu

PlotRange only includes dates for which there is data:

https://wolfram.com/xid/09bnnlsrj-qr603t

PlotTheme (2)
ScalingFunctions (2)
Prices are normally shown on a linear scale:

https://wolfram.com/xid/09bnnlsrj-20rzye

Show prices on a logarithmic scale:

https://wolfram.com/xid/09bnnlsrj-ewnozi

TrendStyle uses green for up trends and red for down trends by default:

https://wolfram.com/xid/09bnnlsrj-ltvatj

Use black for up trends and red for down trends:

https://wolfram.com/xid/09bnnlsrj-cjm17n


https://wolfram.com/xid/09bnnlsrj-0xg6c4

TrendStyle combines with ChartBaseStyle:

https://wolfram.com/xid/09bnnlsrj-7mow4s

With TrendStyle set to None, the base style is used for up trends and empty bars for down trends:

https://wolfram.com/xid/09bnnlsrj-55jmr5

TrendStyle->style uses style for up trends and empty bars for down trends:

https://wolfram.com/xid/09bnnlsrj-xlxn3l

Properties & Relations (3)Properties of the function, and connections to other functions
Use InteractiveTradingChart to visualize and interactively analyze financial data:

https://wolfram.com/xid/09bnnlsrj-mbfoxz

Use PointFigureChart, LineBreakChart, RenkoChart, and KagiChart to analyze the relation of financial prices and time:

https://wolfram.com/xid/09bnnlsrj-ddxqkg

Use DateListPlot to visualize financial data:

https://wolfram.com/xid/09bnnlsrj-dwx0ap

Wolfram Research (2010), TradingChart, Wolfram Language function, https://reference.wolfram.com/language/ref/TradingChart.html (updated 2025).
Text
Wolfram Research (2010), TradingChart, Wolfram Language function, https://reference.wolfram.com/language/ref/TradingChart.html (updated 2025).
Wolfram Research (2010), TradingChart, Wolfram Language function, https://reference.wolfram.com/language/ref/TradingChart.html (updated 2025).
CMS
Wolfram Language. 2010. "TradingChart." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2025. https://reference.wolfram.com/language/ref/TradingChart.html.
Wolfram Language. 2010. "TradingChart." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2025. https://reference.wolfram.com/language/ref/TradingChart.html.
APA
Wolfram Language. (2010). TradingChart. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/TradingChart.html
Wolfram Language. (2010). TradingChart. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/TradingChart.html
BibTeX
@misc{reference.wolfram_2025_tradingchart, author="Wolfram Research", title="{TradingChart}", year="2025", howpublished="\url{https://reference.wolfram.com/language/ref/TradingChart.html}", note=[Accessed: 19-June-2025
]}
BibLaTeX
@online{reference.wolfram_2025_tradingchart, organization={Wolfram Research}, title={TradingChart}, year={2025}, url={https://reference.wolfram.com/language/ref/TradingChart.html}, note=[Accessed: 19-June-2025
]}