Question Details

No question body available.

Tags

r

Answers (2)

January 18, 2026 Score: 3 Rep: 76,438 Quality: Low Completeness: 60%

You're close, just Vectorize() it.

z
January 18, 2026 Score: 0 Rep: 105,804 Quality: Low Completeness: 40%

You could try

library(plotly) expandgrid(x = mgrid, y = sdgrid) %>% mutate(z = map2dbl(x, y, NeglogLikNorm2)) %>% xtabs(formula = z ~ .) %>% plot_ly(z = ., type = "contour")