adding regression line per group with ggplot2I'm not quite sure whether that's what you want, but have you tried the following?
use sprintf to join back into a single string specifying the fmt for adding the leading zeros, create the condition in ifelse to return that new format when there is - or else the old one.
The reason for this problem is that we have used multiple “fill” functions simultaneously. The ggplot2 package specifies all colors at the same time. So if we add multiple functions of the same type, ggplot2 gets confused. 也就是说它有一个 fill=group 了 后面在改颜色的时候加上 scale_fi...