-
Notifications
You must be signed in to change notification settings - Fork 10
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
Add indentation when knit_print()
stopping rule list
#836
Comments
Thank you for making this suggestion. I agree it's necessary - it's been on my "to do" list for a while. I will review asap. |
A couple of "nice-to-haves":
|
Thank you for this quick reply.
|
Summary
knit_print()
is a convenient way of rendering reader-friendly output ofcrmPack
objects in Rmd report. But I see some improvement in the way ofknit_print.StoppingList()
.Currently there is no indentation added to the rendered stopping rule list. So if there are nested stopping rule list, they will all be at the same level, such as what is shown in the vignette, or an example as follows:
Created on 2024-06-25 with reprex v2.1.0
The rendered output of these rules are all at the same level.
If any of the following rules are
TRUE
:If all of the following rules are
TRUE
:≥ 3 cohorts dosed: If 3 or more cohorts have been treated.
P(0.2 ≤ prob(DLE | NBD) ≤ 0.35) ≥ 0.5: If the probability of toxicity at the next best dose is in the range [0.20, 0.35] is at least 0.50.
≥ 20 patients dosed: If 20 or more participants have been treated.
What's the problem this feature will solve?
I think some indentation at the beginning of these lists are necessary so the rendered output one can easily see which rules belongs to which list, such as
If any of the following rules are
TRUE
:If ALL of the following rules are
TRUE
:≥ 3 cohorts dosed: If 3 or more cohorts have been treated.
P(0.2 ≤ prob(DLE | NBD) ≤ 0.35) ≥ 0.5: If the probability of toxicity at the next best dose is in the range [0.20, 0.35] is at least 0.50.
≥ 20 patients dosed: If 20 or more participants have been treated.
Currently I'm using a customized
knit_print()
that pads additional spaces to the begining of the output accordingly to achieve this. But I believe this feature would improve the readability and is worth considering to add into the package. If you like the idea I can submit a PR.This issue can be related to #803 and #774
The text was updated successfully, but these errors were encountered: