plot_spectrum {dsa}R Documentation

Plot the periodogram of a daily time series

Description

Plot the periodogram of a daily time series

Usage

plot_spectrum(
  x,
  xlog = FALSE,
  size = 1,
  color = "black",
  vline_color = "#6F87B2"
)

Arguments

x

xts or ts, daily timeseries

xlog

should x-axis be log transformed

size

linesize

color

color of line

vline_color

color of vertical lines

Details

Plot uses ggplot2 and can be changed accordingly. The spectrum is build around the spec.pgram() function

Author(s)

Daniel Ollech

Examples

x <- daily_sim(3)$original
plot_spectrum(x)

[Package dsa version 1.0.12 Index]