|
|
@ -29,11 +29,15 @@ ggcorrplot<-function(df, var, color="#FFFFFF00", stat="signif", tri="all"){ |
|
|
|
gather(Var2, Value, -Var1) %>% filter(!is.na(Value)) |
|
|
|
|
|
|
|
df.pval$Value<-round(df.pval$Value, 3) |
|
|
|
|
|
|
|
if (!stat %in% c("signif","none","pval")){stat<-"signif"} |
|
|
|
if (stat=="signif"){ |
|
|
|
df.pval$Value<-gtools::stars.pval(df.pval$Value) |
|
|
|
} |
|
|
|
|
|
|
|
if (stat=="none"){ |
|
|
|
df.pval$Value<-"" |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
df$Var1<-factor(df$Var1, levels=order$x) |
|
|
|
df$Var2<-factor(df$Var2, levels=order$y) |
|
|
|
|
|
|
|