Skip to content

Commit 04eadf7

Browse files
added option to format mean value and also adding vignette file to test the function. testing-format-statistics.Rmd file can be deleted after test
1 parent 58842de commit 04eadf7

1 file changed

Lines changed: 38 additions & 0 deletions

File tree

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
---
2+
title: "Untitled"
3+
author: "Jeetender Singh Chauhan"
4+
date: "`r Sys.Date()`"
5+
output: html_document
6+
---
7+
8+
```{r setup, include=FALSE}
9+
knitr::opts_chunk$set(echo = TRUE)
10+
```
11+
12+
13+
14+
```{r , echo=FALSE}
15+
library(metalite)
16+
library(boxly)
17+
18+
# Step 1: Source your modified prepare_boxly.R file
19+
# (Update the path to where your modified file is saved)
20+
source("~/boxly_format_mean_value/R/prepare_boxly.R")
21+
22+
# Step 2: Create metadata
23+
meta <- meta_boxly(
24+
boxly_adsl,
25+
boxly_adlb,
26+
population_term = "apat",
27+
observation_term = "wk12"
28+
)
29+
30+
# Step 3: Prepare data with 2 decimal places for mean
31+
outdata <- prepare_boxly(meta, mean_decimal = 5)
32+
33+
# Step 4: Generate the interactive box plot
34+
boxly(outdata)
35+
36+
```
37+
38+
Note that the `echo = FALSE` parameter was added to the code chunk to prevent printing of the R code that generated the plot.

0 commit comments

Comments
 (0)