Closed sneumann closed 6 years ago
Running with plot = FALSE
worked fine. Can I help debugging the above figure margins too large
?
Ideas what I should check ? Yours, Steffen.
Hi,
Thanks for reporting. I can't say much about this error yet. I'd guess that the jpeg size is too small, but I can't say why, as IPO tries to make the device as large as needed.
Thanks for your offer to help. You could look at the plotContours
-function and with the respective values of model
and maximum_slice
to see what makes it fail. It would also be interesting to see what happens if plot_name
is NULL
. I'll have a look as well.
Ok, I just saw that you're using subdir = NULL
, which results in plot_name = NULL
. So maybe it's because your graphic device (e.g. Rstudio plot window) is too small. Does the error also occur when you set subdir
to a subdirectory?
worked nicely with plotting and a subdirectory. So maybe double checking
plot==TRUE & !is.null(subdir)
would help. Yours, Steffen
Thanks for the reply. I could reproduce the error now. The error happens in your example, as you are optimizing 6 parameters, which results in a plot of 6 choose 2 = 15 plots in a single graphic device. If subdir
is NULL
, IPO tries to plot to the standard graphics device. So it might happen, that your graphics device is too small to hold all these plots, which is not controllable by IPO.
I'll fix this by catching potential errors, because of course IPO should not crash in this case.
A potential new feature to further address this error is a plot function to make it possible for the user to (re)generate the plots after the calculations are done. This should be possible, as the results hold all necessary information. I'll add it to my list of potential new features.
For now for all interested people, here's a sample code to generate the plots manually based on your example:
# needed functions from utils.R
# - getMaximumLevels
# - expand.grid.subset
# - getMaxSettings
# - plotContours
step <- 1 # DoE step to plot
model <- resultRetcorGroup[[step]]$model
max_settings <- getMaximumLevels(model)
maximum_slice <- max_settings[1,-1]
plotContours(model = model, maximum_slice = maximum_slice, plot_name = NULL)
Hi,
when running the code from the vignette on own files, and changing to centWave/loess:
I get an error in the DoE plotting:
Yours, Steffen