I am trying to move my direct labels just slightly to the left, not one group but all groups. By default dl.move only moves one group at a time.
library(directlabels)
library(ggplot2)
count <- c(1,5,6,7,8,8)
year <- c(rep(c(2000,2001,2002),2))
group <- c(rep("A",3),rep("B",3))
c <- data.frame(year,count,group)
p <- ggplot(c, aes(x=year, y=count, colour=group)) + geom_line()
direct.label(p, "first.points")
I can move one point with...
kif <- dl.move("A", hjust=2, vjust=0)
direct.label(p, list("first.points",kif))
but I'd ideally just want to move the whole thing over a by the same hjust. Is there some silly syntax I've totally missed?
dl.trans(x=x-0.1)
moves everything to the left 0.1cm.
direct.label(p, list(dl.trans(x=x-0.1), "first.qp"))