---
title: PKCL01
subtitle: Listing of Drug A Concentration by Treatment Group, Patient and Nominal Time
---
------------------------------------------------------------------------
{{< include ../../_utils/envir_hook.qmd >}}
```{r setup, echo = FALSE, warning = FALSE, message = FALSE}
library(rlistings)
library(dplyr)
adpc <- random.cdisc.data::cadpc
analyte <- "Plasma Drug X"
out <- adpc %>%
filter(PARAM == analyte) %>%
select(ARM, USUBJID, VISIT, NFRLT, AFRLT, AVAL)
var_labels(out) <- c(
ARM = "Treatment Group",
USUBJID = "Subject ID",
VISIT = "Visit",
NFRLT = paste0("Nominal Sampling\nTime (", adpc$RELTMU[1], ")"),
AFRLT = paste0("Actual Time\nFrom First\nDose (", adpc$RELTMU[1], ")"),
AVAL = paste0("Concentration\n(", adpc$AVALU[1], ")")
)
```
```{r include = FALSE}
webr_code_labels <- c("setup")
```
{{< include ../../_utils/webr_no_include.qmd >}}
## Output
:::: panel-tabset
## Standard Listing
::: {.panel-tabset .nav-justified group="webr"}
## {{< fa regular file-lines sm fw >}} Preview
```{r lsting, test = list(lsting = "lsting")}
lsting <- as_listing(
out,
key_cols = c("ARM", "USUBJID", "VISIT"),
disp_cols = names(out),
main_title = paste(
"Listing of",
analyte,
"Concentration by Treatment Group, Subject and Nominal Time, PK Population\nProtocol: xxnnnnn"
),
subtitles = paste("Analyte:", analyte)
)
head(lsting, 20)
```
```{r include = FALSE}
webr_code_labels <- c("lsting")
```
{{< include ../../_utils/webr.qmd >}}
:::
## Data Setup
```{r setup}
#| code-fold: show
```
::::
{{< include ../../_utils/save_results.qmd >}}
{{< include ../../repro.qmd >}}