Allegedly, you have to create a new function based on label_both in order to return bold labels, but so far my attempts have ended with the terrible Error in variable[[i]] : subscript out of bounds .
An alternative to this is to create a function to create the desired label. This is similar to this answer . In this function, you add a prefix to the values โโof the variable and make them bold.
make_labels = function(string, prefix = "cyl: ") { x = paste0(prefix, as.character(string)) do.call(expression, lapply(x, function(y) bquote(bold(.(y))))) }
Now use this function in as_labeller for the variable "cyl" in facet_wrap . You want to change the default label from as_labeller to label_parsed so that the expression is parsed correctly. Use label_both for another variable.
ggplot(mpg, aes(displ, hwy)) + geom_point() + facet_wrap(c("cyl", "drv"), labeller = labeller(cyl = as_labeller(make_labels, default = label_parsed), drv = label_both))

source share