Commit 8325dfaa authored by Antonio Politi's avatar Antonio Politi

Change of color palett

parent 3162ea3d
......@@ -36,7 +36,7 @@ inData$model = factor(inData$model, levels = varNames[seq_plot])
#-----
setwd(outdir)
pChi2<- ggplot(inData, aes(x = model, y = norm, fill = model)) + geom_bar(stat = "identity") + coord_cartesian(ylim= c(20,55)) +
theme_classic(base_size = 8) + xlab('') + ylab('Sum of squared \n residuals') +
theme_classic(base_size = 8) + xlab('') + ylab('Sum of squared \n residuals') + scale_fill_brewer(palette="Set2")+
theme(legend.position = 'none', axis.line.x = element_line(color="black", size = 0.5),
axis.line.y = element_line(color="black", size = 0.5)) +
theme(axis.text.x = element_blank(),
......@@ -49,9 +49,8 @@ cp <- unique(gp$data[[1]]["fill"])
ggsave(filename="production_rates_Chi2.pdf", plot=pChi2, width = 71, height = 30, units = 'mm')
# -----
ptaum<- ggplot(inData, aes(x = model, y = 1/kM + tauM, fill = model)) + geom_bar(stat = "identity") +
coord_cartesian(ylim= c(0,50), expand = c(0), xlim = c(0.4,3.6)) +
coord_cartesian(ylim= c(0,50), expand = c(0), xlim = c(0.4,3.6)) + scale_fill_brewer(palette="Set2")+
theme_classic(base_size = 8) + xlab('') + ylab('Maturation time (min)\n') +
theme(legend.position = 'none', axis.line.x = element_line(color="black", size = 0.5),
axis.line.y = element_line(color="black", size = 0.5)) +
......@@ -80,8 +79,7 @@ seq_plot = c(1, 2, 3)
for (i in seq_along(fnames) ) {
tmpCsv = read.csv(fnames[i], skip=0, sep='\t')
tmpCsv['model'] = varNames[i]
if (i== 2) {
if (i== 2) {
tmpCsv['ProdDensity_inner'] = tmpCsv['ProdDensity_inner']*0.5
}
inData = rbind(inData, tmpCsv)
......@@ -92,7 +90,7 @@ inData$model = factor(inData$model, levels = varNames[seq_plot])
p <- ggplot(inData, aes(time, ProdDensity_inner, colour = model)) + geom_line(size = 1) + theme_classic(base_size = 8) +
coord_cartesian(ylim = c(0, 0.2), xlim = c(0, 50)) + facet_wrap(~ model, ncol = 1) + xlab('Time after AO (min)') +
ylab(expression(paste("Production density (pores/", mu, m^2, "/min)"))) +
theme(legend.position = 'top',
theme(legend.position = 'none',
strip.background = element_blank(), axis.line.y = element_blank(), #element_line(color="black", size = 0.5),
axis.line.x = element_blank(),
strip.text.x = element_text(size = 8, angle = 0),
......@@ -120,7 +118,7 @@ addOpt <- function(p) {
p <- p + xlab(' Time after AO (min)') +
scale_x_continuous(expand = c(0, 0), limits = c(0,120), breaks=seq(0,120,20)) +
scale_y_continuous(expand = c(0, 0), limits = c(0, 13), breaks=seq(0,13,4)) +
theme_classic(base_size = 8) +
theme_classic(base_size = 8) + scale_colour_brewer(palette="Set2") +
theme(legend.position = 'none', axis.line.x = element_line(color="black", size = 0.5),
axis.line.y = element_line(color="black", size = 0.5)) +
theme(axis.text.x = element_text(size=8),
......@@ -150,7 +148,6 @@ for (i in seq_along(fnames) ) {
tmpCsv = read.csv(fnames[i], skip=0, sep='\t')
tmpCsv['model'] = varNames[i]
tmpCsv['nrpar']= nrpar[i]
inData = rbind(inData, tmpCsv)
}
......@@ -158,7 +155,7 @@ inData$model = factor(inData$model, levels = varNames[seq_plot])
# ----
setwd(outdir)
pint_inter <- ggplot() + geom_bar(data=denData, stat = 'identity', width = 1.5, aes(time, int_avg, fill = 'red')) +
geom_line(data = inData, size = 0.8, lty = 2, aes(time, inter_i, group = model, colour = model)) + ylab(expression(paste("Intermediate density (pores/", mu, m^2, ")")))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment