From 3c09102f3e3f6a97e0a72c746362dbb8a341c3e9 Mon Sep 17 00:00:00 2001 From: Saket Choudhary Date: Mon, 8 Apr 2024 19:00:57 +0530 Subject: [PATCH] update to visualization --- DESCRIPTION | 4 ++-- R/visualization.R | 6 +++--- docs/404.html | 2 +- docs/LICENSE-text.html | 2 +- .../figure-html/unnamed-chunk-4-1.png | Bin 98731 -> 96519 bytes docs/articles/index.html | 2 +- docs/authors.html | 6 +++--- docs/deps/jquery-3.6.0/jquery-3.6.0.js | 2 -- docs/deps/jquery-3.6.0/jquery-3.6.0.min.js | 2 +- docs/deps/jquery-3.6.0/jquery-3.6.0.min.map | 2 +- docs/index.html | 2 +- docs/pkgdown.yml | 4 ++-- docs/reference/CleanAmericanStates.html | 2 +- docs/reference/CleanCanadaStates.html | 2 +- docs/reference/CleanIndianStates.html | 2 +- docs/reference/CleanSouthAfricanStates.html | 2 +- docs/reference/CollapseLineageToVOCs.html | 2 +- docs/reference/CombineSequencedCases.html | 2 +- docs/reference/CountsToPrevalence.html | 2 +- docs/reference/CovmullerTheme.html | 2 +- docs/reference/FilterGISAIDIndia.html | 2 +- docs/reference/FixDate.html | 2 +- docs/reference/FormatGISAIDMetadata.html | 2 +- docs/reference/GeocodeAddress.html | 2 +- docs/reference/GetFiletype.html | 2 +- .../GetIndiaConfirmedCasesCumulative.html | 2 +- .../GetIndiaConfirmedCasesMonthlyLong.html | 2 +- .../GetIndiaConfirmedCasesWeeklyLong.html | 2 +- .../GetIndiaDailyCasesCumulative.html | 2 +- docs/reference/GetIndiaDailyData.html | 2 +- .../GetIndiaDeceasedCasesCumulative.html | 2 +- docs/reference/GetIndiaHospitalization.html | 2 +- docs/reference/GetIndianStates.html | 2 +- docs/reference/GetMonthYear.html | 2 +- docs/reference/GetVOCs.html | 2 +- docs/reference/PlotSequencedPropHeatmap.html | 2 +- docs/reference/PlotTotalHeatmap.html | 2 +- docs/reference/ReadAuspiceInstrument.html | 2 +- docs/reference/ReadAuspiceMetadata.html | 2 +- docs/reference/ReadGISAIDMetada.html | 2 +- docs/reference/SanitizeColumn.html | 2 +- docs/reference/SummarizeVariantsDatewise.html | 2 +- .../reference/SummarizeVariantsMonthwise.html | 2 +- docs/reference/SummarizeVariantsWeekwise.html | 2 +- .../TotalSequencesPerMonthCountrywise.html | 2 +- .../TotalSequencesPerMonthStatewise.html | 2 +- docs/reference/index.html | 2 +- vignettes/Introduction.Rmd | 2 +- vignettes/VariantAnimation-Australia.Rmd | 2 +- vignettes/VariantAnimation-Brazil.Rmd | 2 +- vignettes/VariantAnimation-Germany.Rmd | 2 +- vignettes/VariantAnimation-India.Rmd | 2 +- vignettes/VariantAnimation-NYC.Rmd | 2 +- vignettes/VariantAnimation-NewYork.Rmd | 2 +- vignettes/VariantAnimation-Singapore.Rmd | 2 +- vignettes/VariantAnimation-Switzerland.Rmd | 2 +- vignettes/VariantAnimation-UK.Rmd | 2 +- vignettes/VariantAnimation-USA.Rmd | 2 +- vignettes/_MultinomialModeling-Germany.Rmd | 2 +- vignettes/_MultinomialModeling_Australia.Rmd | 2 +- vignettes/_MultinomialModeling_Canada.Rmd | 2 +- vignettes/_MultinomialModeling_India.Rmd | 2 +- .../_MultinomialModeling_SouthAfrica.Rmd | 2 +- vignettes/_MultinomialModeling_UK.Rmd | 2 +- vignettes/_SouthAfrica_contrast_India.Rmd | 2 +- vignettes/_VariantAnimation-Bengaluru.Rmd | 2 +- vignettes/_VariantAnimation-Chennai.Rmd | 2 +- vignettes/_VariantAnimation-Delhi.Rmd | 2 +- vignettes/_VariantAnimation-Gujarat.Rmd | 2 +- vignettes/_VariantAnimation-Hyderabad.Rmd | 2 +- vignettes/_VariantAnimation-Jaipur.Rmd | 2 +- vignettes/_VariantAnimation-Kerala.Rmd | 2 +- vignettes/_VariantAnimation-Maharashtra.Rmd | 2 +- vignettes/_VariantAnimation-Mumbai.Rmd | 2 +- vignettes/_VariantAnimation-Pune.Rmd | 2 +- vignettes/_VariantAnimation-SouthAfrica.Rmd | 2 +- vignettes/_VariantAnimation-Tamilnadu.Rmd | 2 +- vignettes/_VariantAnimation-Telangana.Rmd | 2 +- vignettes/_VarinatAnimation-Kolkata.Rmd | 2 +- 79 files changed, 83 insertions(+), 85 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 8b7bab24..388a495e 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,8 +1,8 @@ Package: covmuller Type: Package Title: A tool to model COVID19 variant prevalence using data from GISAID -Version: 0.1.2.0007 -Date: 2024-01-21 +Version: 0.1.3.9001 +Date: 2024-04-08 Author: Saket Choudhary Maintainer: Saket Choudhary Description: covmuller can be used to process data from GISAID and diff --git a/R/visualization.R b/R/visualization.R index d12b8e62..77337e52 100644 --- a/R/visualization.R +++ b/R/visualization.R @@ -114,7 +114,7 @@ PlotSequencedPropHeatmap <- function(df) { #' @importFrom magrittr %>% #' @importFrom tibble deframe #' @importFrom ggplot2 aes_string coord_cartesian ggplot geom_bar geom_text labs scale_y_continuous scale_x_discrete xlab ylab guide_axis position_dodge -#' @importFrom scales comma label_percent label_number cut_short_scale +#' @importFrom scales append comma label_percent label_number cut_short_scale #' @importFrom ggtext element_markdown #' @importFrom patchwork wrap_plots #' @export @@ -150,7 +150,7 @@ BarPlot <- function(df, xaxis = "MonthYear", size = 3 ) } else { - df[, paste0(yaxis, "_acc")] <- label_number(accuracy = 1, scale_cut = cut_short_scale())(values) + df[, paste0(yaxis, "_acc")] <- label_number(accuracy = 1, scale_cut = append(cut_short_scale(), 1, 1))(values) p <- p + geom_text( data = df, mapping = aes_string( @@ -180,7 +180,7 @@ BarPlot <- function(df, xaxis = "MonthYear", size = 3 ) } - p <- p + scale_y_continuous(labels = label_number(accuracy = 1, scale_cut = cut_short_scale())) + + p <- p + scale_y_continuous(labels = label_number(accuracy = 1, scale_cut = append(cut_short_scale(), 1, 1))) + scale_x_discrete(guide = guide_axis(angle = xangle)) + xlab("") + ylab(ylabel) + diff --git a/docs/404.html b/docs/404.html index 2a8fb0e0..6289a754 100644 --- a/docs/404.html +++ b/docs/404.html @@ -30,7 +30,7 @@ covmuller - 0.1.2.0007 + 0.1.3.9001