Skip to content

Commit

Permalink
fix error from get_horizontal_spacing()
Browse files Browse the repository at this point in the history
fix error from get_horizontal_spacing() when right.space, left.space, col.right.pos and col.left.pos arguments are all specified
  • Loading branch information
neilstats committed Jun 6, 2024
1 parent c204892 commit 19104be
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Title: Create CKB Plots
Description: ckbplotr provides functions to help create and style plots in R.
It is being developed by, and primarily for, China Kadoorie Biobank
researchers.
Version: 0.11.0
Version: 0.11.1
Authors@R:
person(given = "Neil",
family = "Wright",
Expand Down
4 changes: 4 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# ckbplotr 0.11.0

* fix error from get_horizontal_spacing() when right.space, left.space, col.right.pos and col.left.pos arguments are all specified.

# ckbplotr 0.11.0

* addaes/addarg in forest_plot() can now also be used for column headings and diamonds.
* addtext in forest_plot() can be used to display plotmath.
* valign and halign arguments added to prepare_figure() and save_figure()
Expand Down
1 change: 1 addition & 0 deletions R/forest-plot.R
Original file line number Diff line number Diff line change
Expand Up @@ -739,6 +739,7 @@ get_horizontal_spacing <- function(right.space,
}

## calculate automatic col.right.pos and col.right.space
text_about_auto_spacing <- NULL
if (is.null(right.space) | is.null(col.right.pos) | is.null(left.space) | is.null(col.left.pos)){
text_about_auto_spacing <- "Automatically calculated horizontal spacing and positioning:\n"
}
Expand Down

0 comments on commit 19104be

Please sign in to comment.