insightsengineering / tern

Table, Listings, and Graphs (TLG) library for common outputs used in clinical trials
https://insightsengineering.github.io/tern/
Other
77 stars 22 forks source link

[Bug]: Line breaks in forest header messes up row alignment #1171

Closed StefanThoma closed 10 months ago

StefanThoma commented 10 months ago

What happened?

A bug happened! I set up my forest plot data table using rtables. Often, this requires line breaks in the header. This then messes up the alignment of the rows.

sessionInfo()

R version 4.0.4 (2021-02-15)
Platform: x86_64-redhat-linux-gnu (64-bit)
Running under: Red Hat Enterprise Linux 8.8 (Ootpa)

Matrix products: default
BLAS:   /usr/lib64/libblas.so.3.8.0
LAPACK: /opt/mango/R/4.0.4/lib/R/lib/libRlapack.so

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C               LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8    LC_PAPER=en_US.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C             LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] readr_1.4.0      ggplot2_3.3.3    lubridate_1.7.10 stringr_1.4.0    rice_3.0         rbmi_1.2.1       broom_0.7.6     
 [8] tidyr_1.1.3      dplyr_1.0.5      filters_0.1.0    EnableRF_0.5.3   tern_0.7.9       rtables_0.5.2    formatters_0.3.3
[15] magrittr_2.0.1  

loaded via a namespace (and not attached):
 [1] nlme_3.1-152         matrixStats_0.58.0   httr_1.4.2           rprojroot_2.0.2      rstan_2.21.2        
 [6] numDeriv_2016.8-1.1  tools_4.0.4          TMB_1.9.1            backports_1.2.1      utf8_1.2.1          
[11] R6_2.5.0             useNEST_1.0.0        DBI_1.1.1            colorspace_2.0-0     withr_2.4.2         
[16] tidyselect_1.1.0     gridExtra_2.3        prettyunits_1.1.1    processx_3.5.1       emmeans_1.7.5       
[21] curl_4.3             compiler_4.0.4       cli_2.4.0            desc_1.3.0           sandwich_3.0-0      
[26] stringfish_0.15.1    scales_1.1.1         checkmate_2.0.0      mvtnorm_1.1-1        callr_3.6.0         
[31] digest_0.6.27        StanHeaders_2.21.0-7 mmrm_0.1.5           pkgconfig_2.0.3      htmltools_0.5.1.1   
[36] rlang_0.4.10         rstudioapi_0.13      generics_0.1.0       RApiSerialize_0.1.0  zoo_1.8-9           
[41] jsonlite_1.7.2       inline_0.3.17        loo_2.4.1            Matrix_1.3-2         Rcpp_1.0.6          
[46] waldo_0.2.5          munsell_0.5.0        fansi_0.4.2          lifecycle_1.0.0      stringi_1.5.3       
[51] multcomp_1.4-16      yaml_2.2.1           MASS_7.3-53.1        pkgbuild_1.2.0       grid_4.0.4          
[56] parallel_4.0.4       crayon_1.4.1         lattice_0.20-41      splines_4.0.4        hms_1.0.0           
[61] ps_1.6.0             pillar_1.6.0         estimability_1.3     codetools_0.2-18     stats4_4.0.4        
[66] pkgload_1.2.1        glue_1.4.2           packrat_0.5.0        V8_3.4.0             remotes_2.3.0       
[71] RcppParallel_5.0.3   vctrs_0.3.7          Rdpack_2.4           testthat_3.0.2       gtable_0.3.0        
[76] purrr_0.3.4          qs_0.24.1            assertthat_0.2.1     rbibutils_2.2.9      xtable_1.8-4        
[81] coda_0.19-4          survival_3.2-10      tibble_3.1.1         TH.data_1.0-10       ellipsis_0.3.1

Relevant log output

No response

Code of Conduct

Contribution Guidelines

Security Policy

shajoezhu commented 10 months ago

Hi @StefanThoma , the forest plot function has been worked on, the version you are using is very outdated. closing this issue for now