You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The default label in the KM curve includes the variable name. This labeling comes from the default output in survfit().
But, it's difficult to imagine a scenario where anyone would want the variable name prefix in the figure. Because we have total control of the inputs with estimate_KM(), we can pretty easily update this to only include the levels without the "varname=" prefix. When there are multiple stratifying variables we can use the interaction() function to construct a more beautiful stratifying variable to include.
I started some updates in a branch called "strata_lbl_updates". So far the "variable_name=" prefix in the legend is removed (and works when there is more than one stratifying variable). I think the output is preferable....thoughts?
It was a conscious decision to keep it in. In our clinical trials we might switch between planned and actual treatment for a subject during analysis. To be very explicit this strata label is useful TRTA = vs TRTP =
That is a very good point! It's important the labeling is clear. I am trying to think of ways that we can keep the messaging clear, but also customizable. I know in my work (including the randomized trials I report on) we would never publish a figure using a raw variable name.
What do you think of dropping the variable name from the levels, and add it to the legend. This way, users have control over whether they want to keep the variable name in the levels or not. In the current state, it can't be customized.
The default label in the KM curve includes the variable name. This labeling comes from the default output in
survfit()
.But, it's difficult to imagine a scenario where anyone would want the variable name prefix in the figure. Because we have total control of the inputs with
estimate_KM()
, we can pretty easily update this to only include the levels without the"varname="
prefix. When there are multiple stratifying variables we can use theinteraction()
function to construct a more beautiful stratifying variable to include.Created on 2022-03-14 by the reprex package (v2.0.1)
Also, what do you think about making the default strata label a blank space instead of include
"strata"
above the levels for every plot?The text was updated successfully, but these errors were encountered: