Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EGT01 - decimal place #298

Open
shino-iwase opened this issue Jan 22, 2025 · 2 comments
Open

EGT01 - decimal place #298

shino-iwase opened this issue Jan 22, 2025 · 2 comments

Comments

@shino-iwase
Copy link

shino-iwase commented Jan 22, 2025

The ECG parameters are measured in integer. Could it be updated properly? I think it can be updated as follows:
.formats = list("n" = "xx", "Mean (SD)" = "xx.x (xx.x)", "Median" = "xx.x", "Min - Max" = "xx - xx"),

For the current outputs generated by Chevron show 3 decimals for Mean, SD and Median, and 2 decimals for min-max. It is too much.

@shino-iwase shino-iwase changed the title EGT01 EGT01 - decimal place Jan 22, 2025
@BFalquet
Copy link

BFalquet commented Jan 23, 2025

Hi @shino-iwase, could you try using the precision argument in chevron? You can specify the precision for each parameter separately. by passing a named list where the name are the parameter code and the value the number of decimals in the min-max statistic.

Please note that the industry standard is to have one more decimal for the other statistics.
You can also change the value everywhere by passing the argument precision = list(default = <i>) where <i> is a positive integer.

e.g.

library(chevron)
#> Registered S3 method overwritten by 'tern':
#>   method   from 
#>   tidy.glm broom
run(egt01, syn_data, precision = list(HR = 0, default = 3))
#>                                    A: Drug X                                B: Placebo                             C: Combination             
#>                                             Change from                               Change from                              Change from    
#>                       Value at Visit          Baseline          Value at Visit         Baseline          Value at Visit          Baseline     
#>   Analysis Visit          (N=15)               (N=15)               (N=15)              (N=15)               (N=15)               (N=15)      
#>   ————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————
#>   Heart Rate                                                                                                                                  
#>     BASELINE                                                                                                                                  
#>       n                     15                                        15                                       15                             
#>       Mean (SD)        76.6 (17.9)                               69.9 (18.8)                              70.5 (18.2)                         
#>       Median               77.5                                      77.2                                     74.1                            
#>       Min - Max          46 - 107                                  26 - 98                                  45 - 115                          
#>     WEEK 1 DAY 8                                                                                                                              
#>       n                     15                   15                   15                  15                   15                   15        
#>       Mean (SD)        71.1 (23.4)          -5.5 (25.1)          71.0 (14.9)          1.1 (23.3)          67.4 (18.9)          -3.0 (23.8)    

@shino-iwase
Copy link
Author

shino-iwase commented Jan 23, 2025

Thank you for your reply. Indeed we can specify it for each study. But it is not efficient as it is common requirement across studies, not study specific. I suggest to implement it as standard into this catalogue and Chevron so that we don't need to customize in each study.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants