Every element of the user interface is accessible through AppleScript, to facilitate Accessibility (assistive devices). This includes candlesticks on the chart and all menus including popup menus.
Without entering into a full explanation of the way AppleScript works, below is an example of how to access buttons and menus.