I am experiencing strange behavior of chart_Series(). After a lot of debugging I stripped it down to this:
Working in RStudio, I have data to be plot using chart_Series(), but it does not work in a script.
I believe everything is right on my side. The function is called and there are proper data in the variable I am trying to plot. If I replace chart_Series() with plot() {R}, plota() {SIT}, or even chartSeries() {Quantmod}, everything works as expected. But the new chart_Series() does not.
If I call the chart_Series() function from the console, it works as expected. For example:
chart_Series(x)
but if I copy/paste this single line into Test.R it doesn't work. All the functions listed above do work. Copy/paste back to console, it works again.
SUMMARY: All the charting functions work from a script or console but chart_Series() works only from console.
I know that chart_Series() will replace chartSeries() when the development is done and it is in aplha phase now. Anyway, I find this behavior strange and I expect it to work from a script if it is working in the console. Maybe I am missing something but I have no idea what.
NOTE: I noticed that e.g. head(x) run from console works as expected, but when I try it from a script, it prints nothing to the console. On the other hand, View(x) works from both places. Being new to R/RStudio, I do not know if this is related problem or expected behavior.