Skip to content

Commit

Permalink
prepare to release fix pending CRAN notes refresh docs
Browse files Browse the repository at this point in the history
  • Loading branch information
certara-smouksassi committed Sep 18, 2023
1 parent 318dba6 commit 470f3f1
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 10 deletions.
Binary file removed Figure_8_4.png
Binary file not shown.
1 change: 1 addition & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ export(forest_plot)
export(get_sample_data)
export(run_interactiveforestplot)
import(data.table, except = c(last,between,first))
importFrom(colourpicker,colourInput)
4 changes: 2 additions & 2 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
* added and exported `expand_modelframe` function
* added the possibility to select the shapes manually via `interval_shape` and `bsv_shape`
* added capability for user to reverse color legend separately via `legend_color_reverse`
* added capability for user to specify text for legend titles via `interval_legend_title` and `shape_legend_title` as well as to control text size via `legend_title_size`
* added capability for user to specify facet text color via `x_facet_text_col` and `y_facet_text_col`
* added capability for user to specify text for legend titles via `interval_legend_title` and `shape_legend_title` as well as to control legend title text size via `legend_title_size`
* added capability for user to specify facet text color via `x_facet_text_col` and `y_facet_text_col` for improved theming support
* added possibility to add different ref line(s)/area(s) by parameter via
`ref_value_by_panel` and `ref_value_by_panel_data` function arguments (not in the shiny, app)

Expand Down
13 changes: 7 additions & 6 deletions R/forest_plot.R
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
#' @importFrom colourpicker colourInput
# ' @importFrom ggplot2 translate_shape_string not yet

# Same as base R `which()` function, but return 0 instead of an empty vector
# if there are no TRUE values in the array
which0 <- function(x) {
Expand Down Expand Up @@ -290,7 +293,7 @@ label_wrap <- function(width) {
#' ref_value_by_panel_data = as.data.frame(
#' plotdata %>%
#' distinct(paramname2,covname) %>%
#' mutate(xintercept=ifelse(paramname2=="CMAX",1,1.2))))
#' dplyr::mutate(xintercept=ifelse(paramname2=="CMAX",1,1.2))))
#'
#' # Example 3
#'
Expand All @@ -314,7 +317,7 @@ label_wrap <- function(width) {
#' # Example 4
#' plotdata <- get_sample_data("dataforest.csv")
#' plotdata <- plotdata %>%
#' mutate(midlabel = format(round(mid,2), nsmall = 2),
#' dplyr::mutate(midlabel = format(round(mid,2), nsmall = 2),
#' lowerlabel = format(round(lower,2), nsmall = 2),
#' upperlabel = format(round(upper,2), nsmall = 2),
#' LABEL = paste0(midlabel, " [", lowerlabel, "-", upperlabel, "]"))
Expand Down Expand Up @@ -684,8 +687,8 @@ forest_plot <- function(
inherit.aes = FALSE,
)+
ggplot2::geom_ribbon(
data = ref_value_by_panel_data %>%
mutate(x= xintercept,
data = cbind(as.data.frame(ref_value_by_panel_data),
x = ref_value_by_panel_data$xintercept,
ymax = Inf,
ymin = -Inf,
fill = area_legend_text),
Expand Down Expand Up @@ -1240,5 +1243,3 @@ draw_key_pointrangeh <- function(data, params, size) {
)
}

# ' @importFrom colourpicker colourInput
# ' @importFrom ggplot2 translate_shape_string
Binary file removed coveffectsplot_full.png
Binary file not shown.
4 changes: 2 additions & 2 deletions man/forest_plot.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 470f3f1

Please sign in to comment.