Noticed that multiplot() will throw error and not plot when using BC/AD mode when there are dates with post-BP/post-bomb values.
It seems that this is caused by the BPtoBCAD() function choking on conversion.
BPtoBCAD <- function(x){
index <- !is.na(x)
if (any(x[index] < 0)){ stop("Post-bomb dates (<0 BP) are not currently supported.") }
res <- matrix(c(x, rep(NA,length(x))), ncol=2)
res[index & x < 1950,2] <- 1950-res[index & x < 1950,1]
res[index & x >= 1950,2] <- 1949-res[index & x >= 1950,1]
return(res[,2])
}
Meanwhile the same dates plot fine using the BP mode. There may be good reasons to exclude them, but feel it might better to give users advice than blank refusal just because of the scale.
Would you consider switching stop() to warning() to allow these to be plotted?
Can PR it if needed, though it's a really teeny one!
Noticed that multiplot() will throw error and not plot when using BC/AD mode when there are dates with post-BP/post-bomb values.
It seems that this is caused by the BPtoBCAD() function choking on conversion.
Meanwhile the same dates plot fine using the BP mode. There may be good reasons to exclude them, but feel it might better to give users advice than blank refusal just because of the scale.
Would you consider switching stop() to warning() to allow these to be plotted?
Can PR it if needed, though it's a really teeny one!