figure fixup

This commit is contained in:
Tanushree Tunstall 2023-02-21 21:01:00 +00:00
parent c1441dc0d6
commit c2d6eb49ea
6 changed files with 35 additions and 28 deletions

View file

@ -9,7 +9,9 @@
source("~/git/LSHTM_analysis/config/alr.R")
source("~/git/LSHTM_analysis/scripts/plotting/get_plotting_dfs.R")
outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
#outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
outdir="~/git/Writing/thesis/tex/images-corrected/alr/"
# add "pos_count" position count column
merged_df3=merged_df3 %>% dplyr::add_count(position)
@ -341,7 +343,7 @@ stability_low_reorder = bp_stability_hmap(
)
png(paste0(outdir,"alr_average_stability-sorted.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"alr_average_stability-sorted.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_high_reorder, stability_centre_reorder, stability_low_reorder,ncol=1),
@ -350,7 +352,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"alr_average_stability-unsorted.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"alr_average_stability-unsorted.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_high, stability_centre, stability_low,ncol=1),
@ -359,7 +361,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"alr_snp.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"alr_snp.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_p_snps_low, logo_p_snps_centre, logo_p_snps_high, ncol=1, align='hv'),
@ -368,7 +370,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"alr_or.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"alr_or.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_or_low, logo_or_centre, logo_or_high, ncol=1, align='hv'),

View file

@ -9,7 +9,8 @@
source("~/git/LSHTM_analysis/config/embb.R")
source("~/git/LSHTM_analysis/scripts/plotting/get_plotting_dfs.R")
outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
#outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
outdir="~/git/Writing/thesis/tex/images-corrected/embb/"
# add "pos_count" position count column
merged_df3=merged_df3 %>% dplyr::add_count(position)
@ -238,7 +239,7 @@ logo_or_high = LogoPlotCustomH(small_df3,
aa_pos_lig3=aa_pos_lig3
)
png(paste0(outdir,"embb_average_stability.png"), height = 8.25, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"embb_average_stability.jpeg"), height = 8.25, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_high, stability_centre, stability_low,ncol=1),
@ -247,7 +248,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"embb_snp.png"), height = 8.25, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"embb_snp.jpeg"), height = 8.25, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_p_snps_low, logo_p_snps_centre, logo_p_snps_high, ncol=1, align='hv'),
@ -256,7 +257,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"embb_or.png"), height = 8.25, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"embb_or.jpeg"), height = 8.25, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_or_low, logo_or_centre, logo_or_high, ncol=1, align='hv'),

View file

@ -9,7 +9,8 @@
source("~/git/LSHTM_analysis/config/gid.R")
source("~/git/LSHTM_analysis/scripts/plotting/get_plotting_dfs.R")
outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
#outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
outdir="~/git/Writing/thesis/tex/images-corrected/gid/"
# add "pos_count" position count column
merged_df3=merged_df3 %>% dplyr::add_count(position)
@ -341,7 +342,7 @@ stability_low_reorder = bp_stability_hmap(
)
png(paste0(outdir,"gid_average_stability-sorted.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"gid_average_stability-sorted.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_high_reorder, stability_centre_reorder,stability_low_reorder, ncol=1),
@ -350,7 +351,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"gid_average_stability-unsorted.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"gid_average_stability-unsorted.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_low, stability_centre, stability_high, ncol=1),
@ -359,7 +360,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"gid_snp.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"gid_snp.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_p_snps_low, logo_p_snps_centre, logo_p_snps_high, ncol=1, align='hv'),
@ -368,7 +369,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"gid_or.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"gid_or.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_or_low, logo_or_centre, logo_or_high, ncol=1, align='hv'),

View file

@ -9,7 +9,8 @@
source("~/git/LSHTM_analysis/config/katg.R")
source("~/git/LSHTM_analysis/scripts/plotting/get_plotting_dfs.R")
outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
# outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
outdir="~/git/Writing/thesis/tex/images-corrected/katg/"
# add "pos_count" position count column
merged_df3=merged_df3 %>% dplyr::add_count(position)
@ -346,7 +347,7 @@ stability_low_reorder = bp_stability_hmap(
)
png(paste0(outdir,"katg_average_stability-sorted.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"katg_average_stability-sorted.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_high_reorder, stability_centre_reorder, stability_low_reorder,ncol=1),
@ -355,7 +356,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"katg_average_stability-unsorted.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"katg_average_stability-unsorted.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_high, stability_centre, stability_low,ncol=1),
@ -364,7 +365,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"katg_snp.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"katg_snp.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_p_snps_low, logo_p_snps_centre, logo_p_snps_high, ncol=1, align='hv'),
@ -373,7 +374,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"katg_or.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"katg_or.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_or_low, logo_or_centre, logo_or_high, ncol=1, align='hv'),

View file

@ -9,7 +9,8 @@
source("~/git/LSHTM_analysis/config/pnca.R")
source("~/git/LSHTM_analysis/scripts/plotting/get_plotting_dfs.R")
outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
#outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
outdir="~/git/Writing/thesis/tex/images-corrected/pnca/"
# add "pos_count" position count column
merged_df3=merged_df3 %>% dplyr::add_count(position)
@ -243,7 +244,7 @@ logo_or_high = LogoPlotCustomH(small_df3,
rm_empty_y=T
)
png(paste0(outdir,"pnca_average_stability.png"), height = 8.25, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"pnca_average_stability.jpeg"), height = 8.25, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_high, stability_centre, stability_low,ncol=1),
@ -252,7 +253,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"pnca_snp.png"), height = 8.25, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"pnca_snp.jpeg"), height = 8.25, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_p_snps_low, logo_p_snps_centre, logo_p_snps_high, ncol=1, align='hv'),
@ -261,7 +262,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"pnca_or.png"), height = 8.25, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"pnca_or.jpeg"), height = 8.25, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_or_low, logo_or_centre, logo_or_high, ncol=1, align='hv'),

View file

@ -9,7 +9,8 @@
source("~/git/LSHTM_analysis/config/rpob.R")
source("~/git/LSHTM_analysis/scripts/plotting/get_plotting_dfs.R")
outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
#outdir="/home/pub/Work/LSHTM/Thesis_Plots/"
outdir="~/git/Writing/thesis/tex/images-corrected/rpob/"
# add "pos_count" position count column
merged_df3=merged_df3 %>% dplyr::add_count(position)
@ -349,7 +350,7 @@ stability_low_reorder = bp_stability_hmap(
)
png(paste0(outdir,"rpob_average_stability-sorted.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"rpob_average_stability-sorted.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_high_reorder, stability_centre_reorder, stability_low_reorder,ncol=1),
@ -358,7 +359,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"rpob_average_stability-unsorted.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"rpob_average_stability-unsorted.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, snp_tile_legend, nrow=1),
cowplot::plot_grid(stability_high, stability_centre, stability_low,ncol=1),
@ -367,7 +368,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"rpob_snp.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"rpob_snp.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_p_snps_low, logo_p_snps_centre, logo_p_snps_high, ncol=1, align='hv'),
@ -376,7 +377,7 @@ cowplot::plot_grid(
)
dev.off()
png(paste0(outdir,"rpob_or.png"), height = 6, width=11.5, unit="in",res=300)
jpeg(paste0(outdir,"rpob_or.jpeg"), height = 6, width=11.5, unit="in",res=300)
cowplot::plot_grid(
cowplot::plot_grid(heat_bar_legend, tile_legend, logoplot_chemistry_legend, nrow=1),
cowplot::plot_grid(logo_or_low, logo_or_centre, logo_or_high, ncol=1, align='hv'),