View source: R/order_of_integration.R
plot_missing_values | R Documentation |
Plots missing values of different types for a time series dataset.
plot_missing_values(y, show_names = FALSE, show_legend = TRUE,
axis_text_size = NULL, legend_size = NULL, cols = NULL)
y |
A ( |
show_names |
Show the time series' names on the plot ( |
show_legend |
Logical indicator whether a legend should be displayed. Default is |
axis_text_size |
Size of the text on the axis. Default takes |
legend_size |
Size of the text in the legend if |
cols |
Vector with colours for displaying the different types of data. If the default is overwritten, four colours must be supplied. |
The function distinguish four types of data: observed data (non-missing) and three missing types. Type "Balanced NA"
indicates where entire rows are missing (NA
). These do not cause unbalancedness as the missing rows can simply be deleted. Type "Unbalanced NA"
are missing values on the beginning or end of the sample, which cause unbalancedness. These affect some (but not all) bootstrap methods, see e.g.~boot_fdr
. Type "Internal NA"
are missing values inside the sample, which need to be removed before the bootstrap unit root tests can be used.
This function requires the package ggplot2
to be installed. If the package is not found, plotting is aborted.
A ggplot2
object containing the missing values plot.
Smeekes, S. and Wilms, I. (2023). bootUR: An R Package for Bootstrap Unit Root Tests. Journal of Statistical Software, 106(12), 1-39.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.