Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

Commit

Permalink
Merge pull request #2 from unhcr/gh-pages
Browse files Browse the repository at this point in the history
Merge with UNHCR rep
  • Loading branch information
maherdaoud committed Jun 12, 2019
2 parents fffa73a + 0d6375b commit ff97f05
Show file tree
Hide file tree
Showing 116 changed files with 3,763 additions and 1,117 deletions.
6 changes: 5 additions & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,11 @@ Depends:
truncnorm,
OpenRepGrid
Suggests:
shiny
shiny,
testthat (>= 2.1.0),
utils
URL: https://github.com/unhcr/koboloadeR
BugReports: https://github.com/unhcr/koboloadeR/issues
RoxygenNote: 6.1.1
VignetteBuilder: utils

5 changes: 5 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ export(kobo_histo)
export(kobo_histo_print)
export(kobo_indicator)
export(kobo_label)
export(kobo_left_align)
export(kobo_load_data)
export(kobo_load_packages)
export(kobo_map_cat)
Expand All @@ -65,6 +66,10 @@ export(kobo_time_parser_UTC)
export(kobo_to_xlsform)
export(kobo_trend)
export(kobo_trend_report)
export(kobo_unhcr_style_bar)
export(kobo_unhcr_style_histo)
export(kobo_unhcr_style_map)
export(kobo_unhcr_style_scatter)
export(kobo_weight)
export(ltbl)
export(multresponse)
Expand Down
2 changes: 0 additions & 2 deletions R/kobo_anonymise.R
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@
#'
#' @author Edouard Legoupil
#'
#' @examples
#' kobo_anonymise()
#'
#' @export kobo_anonymise
#'
Expand Down
311 changes: 182 additions & 129 deletions R/kobo_create_indicators.R

Large diffs are not rendered by default.

223 changes: 128 additions & 95 deletions R/kobo_crunching_report.R

Large diffs are not rendered by default.

138 changes: 82 additions & 56 deletions R/kobo_dico.R

Large diffs are not rendered by default.

248 changes: 130 additions & 118 deletions R/kobo_dummy.R

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion R/kobo_get_theme.R
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
#' @export kobo_get_theme
#'

kobo_get_theme <- function(form = "form.xls") {
kobo_get_theme <- function() {

themeList <- list()

Expand Down
22 changes: 22 additions & 0 deletions R/kobo_left_align.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#' @name kobo_left_align
#' @rdname kobo_left_align
#' @title UNHCR ggplot2 theme
#'
#' @description Left align chart title and subtitle on a ggplot2
#'
#' @return Return better chart
#'
#' @author Edouard Legoupil - with inspiration from bbc
#'
#' @examples
#' kobo_left_align()
#'
#' @export kobo_left_align
#'

kobo_left_align <- function(plot_name, pieces){
grob <- ggplot2::ggplotGrob(plot_name)
n <- length(pieces)
grob$layout$l[grob$layout$name %in% pieces] <- 2
return(grob)
}
Loading

0 comments on commit ff97f05

Please sign in to comment.