Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

autoplot.ichimoku

autoplot.ichimoku


Description

Plot static Ichimoku Kinko Hyo cloud charts from ichimoku objects.

Usage

## S3 method for class 'ichimoku'
autoplot(object, from, to, ticker, theme = "default", gaps = FALSE, ...)

Arguments

object

an object of class 'ichimoku'.

from

(optional) a starting date/time to subset the plot.

to

(optional) an ending date/time to subset the plot.

ticker

(optional) specify a ticker (or other text) to include in the chart heading. If not set, the ticker saved within the ichimoku object will be used.

theme

with a default of 'default'. This can also be set to 'dark' or 'solarized' to select the desired colour scheme.

gaps

set to FALSE by default to remove weekend and holiday gaps. Set to TRUE for a continuous timescale axis, but with gaps for non-trading days.

...

other arguments to be passed along.

Details

This function is an S3 method for the generic function autoplot() for class 'ichimoku'. It can be invoked by calling autoplot(x) on an object 'x' of class 'ichimoku'.

Value

Returns a ggplot2 object with S3 classes 'gg' and 'ggplot'.

Further Details

Please refer to the reference vignette by running: vignette("reference", package = "ichimoku")

Examples

cloud <- ichimoku(sample_ohlc_data, ticker = "TKR")

autoplot(cloud)
autoplot(cloud, from = "2020-05-15", to = "2020-10-30", theme = "dark")
autoplot(cloud, ticker = "TKR Co.", theme = "solarized", gaps = TRUE)

ichimoku

Compute and Plot Ichimoku Kinko Hyo Cloud Charts

v0.1.2
GPL (>= 3)
Authors
Charlie Gao [aut, cre]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.