Browse Source

Styling in ggplot2, adding myTheme

Andrej 1 week ago
parent
commit
d398f95ba1
1 changed files with 7 additions and 0 deletions
  1. 7 0
      R/roc.R

+ 7 - 0
R/roc.R

@@ -288,6 +288,13 @@ simple.plotROCgg<-function(df,vars,cols,x=0.7,y=0.3,unit="ml",precise="FALSE",ta
       ggplot2::ylab('sensitivity')+
       ggplot2::ylab('sensitivity')+
       ggplot2::scale_color_manual(name='Variables',values=colors_used)+
       ggplot2::scale_color_manual(name='Variables',values=colors_used)+
       ggplot2::guides(color = ggplot2::guide_legend(position = "inside"))+
       ggplot2::guides(color = ggplot2::guide_legend(position = "inside"))+
+      myTheme()+
       ggplot2::theme(legend.position.inside=base::c(x,y))
       ggplot2::theme(legend.position.inside=base::c(x,y))
 
 
 }
 }
+
+myTheme<-function(){
+   ggplot2::theme(
+            axis.text=element_text(size=12),
+            axis.title=element_text(size=14,face="bold"))
+}