Kaggle / docker-rstats

Kaggle R docker image
Apache License 2.0
142 stars 90 forks source link

Problem with Rmd script #4

Closed matsavage closed 7 years ago

matsavage commented 7 years ago

I am having a problem with the following block of code when running an Rmd script;

fit <- auto.arima(northts, lambda=0, d=0, D=1, max.order=4,
                  stepwise=FALSE, approximation=FALSE)
autoplot(forecast(fit, h = 36)) + xlim(2010, 2018) 

Executing this results in a 'unsupported character in output path' error, and seems to only arise fro plotting the figure, which is strange as ggplot seems to be supported well everywhere else, and I get the same error just using the basic 'plot(forecast(fit, h = 36)) + xlim(2010, 2018)' too.

The Rmd file in question can be found here

nerdcha commented 7 years ago

Hi Mat, it seems that the Rmd renderer (or maybe ggplot) wants to save the plots as pngs with filenames based on the names of the Rmd code chunks that they're in. So the issue in this case was the brackets in Auto ARIMA (NH)-1.png. Sorry that wasn't clear! We'll see about improving the feedback in this type of case.

matsavage commented 7 years ago

Ah, thanks a lot! I thought it was a problem with autoplot, and completely overlooked the Rmd titles. I'll keep this in mind!