title: ggplot2, change title size
body: <p>I would like to have my main title and axis title have the same font size as the annotated text in my plot.</p>
  
  <p>i used theme_get() and found that text size is 12, so I did that in my theme statement - this did not work. I also tried to send the relative size to 1, and this did not work</p>
  
  <p><img src="https://i.stack.imgur.com/ORwka.jpg" alt="enter image description here">
  I was hoping someone could please help me. </p>
  
  <p>Code is below</p>
  
  <pre><code>library(ggplot2)
  library(gridExtra)  #to set up plot grid
  library(stringr)  #string formatting functions
  library(plyr)  #rbind.fill function
  library(reshape2)  #transformation of tables
  
  dat&lt;-data.frame(
  est=c(2.75,2.95,2.86,2.99),
  ucl=c(2.92,3.23,3.38,4.91),
  lcl=c(2.24,1.67,2.44,1.82),
  ord=c(1,2,1,2)
  )
  dat$varname&lt;-c('Estimate','Predictive','Estimate','Predictive')
  dat$grp&lt;-c('Cobalt','Cobalt','Chromium','Chromium')
  
  for (i in unique(dat$grp)) {
    dat &lt;- rbind.fill(dat, data.frame(grp = i, ord=0,
                                      stringsAsFactors = F))
  }
  
  dat$grp_combo &lt;- factor(paste(dat$grp, dat$ord, sep = ", "))
  dat$grpN &lt;- as.numeric(dat$grp_combo)
  
  
  
  rng &lt;- c(0,6)
  scale.rng &lt;-1
  
  
  xstart=-(max(dat$grpN)+2)
  xend=4
  
  
  ThemeMain&lt;-theme(legend.position = "none", plot.margin = unit(c(0,0,0, 0), "npc"), 
                   panel.margin = unit(c(0,0, 0, 0), "npc"), 
                   title =element_text(size=12, face='bold'),
                   axis.text.y = element_blank(), 
                   axis.text.x = element_text(color='black'),
                   axis.ticks.y = element_blank(),
                   axis.title.x = element_text(size=12,color='black',face='bold')
                   )
  BlankSettings &lt;- theme(legend.position = "none", 
                         title =element_text(size=12, face='bold'),
                         plot.margin = unit(c(0,0, 0, 0), "npc"), 
                         panel.margin = unit(c(0,0, 0, 0), "npc"),              
                         axis.text.x = element_text(color='white'),                             
                         axis.text.y = element_blank(), 
                         axis.ticks.x = element_line(color = "white"),
                         axis.ticks.y=element_blank(),
                         axis.title.x = element_text(size=12,color='white',face='bold'),
                         panel.grid = element_blank(),panel.grid.major = element_blank(),panel.background = element_blank()
                         )
  
  pd &lt;- position_dodge(width = 0.7)
  
  #######################################################################################################
  #MAIN PLOT
  #######################################################################################################
  mainPart&lt;-
    ggplot(dat, aes(x=-grpN,y=est, ymin=lcl, ymax=ucl, group=1)) +
    scale_y_continuous(name=NULL, breaks=seq(rng[1], rng[2], scale.rng), limits=c(rng[1], rng[2]), expand=c(0,0)) + 
    ylab('Ion Concentration') +
    ggtitle('Mean with 95% HDI')+
    #geom_segment(aes(x=xstart, xend=0, y=0, yend=0), linetype=3, alpha=0.01) +
    geom_linerange(aes(linetype="1"),position=pd) +
    geom_point(aes(shape="1"), fill="white",position=pd) +
    coord_flip() +
    scale_x_continuous(limits=c(xstart,xend), expand=c(0,0))+xlab(NULL)+
    ThemeMain
  
  #######################################################################################################
  #varnameS
  #######################################################################################################
  # ystart &amp; yend are arbitrary. [0, 1] is
  # convinient for setting relative coordinates of
  # columns
  ystart = 0
  yend = 1
  p1 &lt;- 
    ggplot(dat, aes(x = -varnameN, y = 0)) + 
    coord_flip() + 
    scale_y_continuous(limits = c(ystart, yend)) + 
    BlankSettings+
    scale_x_continuous(limits = c(xstart, xend), expand = c(0, 0)) + 
    xlab(NULL) + 
    ylab('') +
    ggtitle('')
  
  studyList&lt;-
    p1 + 
    with(unique(dat[is.na(dat$varname),c("grpN","grp")]), annotate("text",label=grp, x=-grpN,y=0, fontface='bold', hjust=0)) + #Variable Group varnames
    with(dat[!is.na(dat$var),],annotate("text",label=varname,x=-grpN,y=0.04, hjust=0))  #Variables
  
  #######################################################################################################
  #EFFECTS
  #######################################################################################################
  f&lt;-function(x) round(x,2)
  dat$msmt&lt;-paste(f(dat$est),' [',f(dat$lcl),', ',f(dat$ucl),']',sep='')
  
  
  effectSizes&lt;-p1+
    annotate("text",x=-dat$grpN, y=0.25,label=ifelse(is.na(dat$varname)==T,'',dat$msmt))
  
  
  
  grid.arrange(ggplotGrob(studyList), ggplotGrob(mainPart), 
               ggplotGrob(effectSizes), ncol = 3, widths = unit(c(0.19, 
                                                                   0.4, 0.41), "npc"))
  </code></pre>