WOLFRAM

Censoring[t,c]

represents a censored event time t with censoring c.

Censoring[{t1,t2,},c]

represents a vector of censored event times ti with censoring c.

Censoring[{t1,t2,},{c1,c2,}]

represents a vector of event times ti with corresponding censoring ci.

Details

  • Censoring[data,cens] is typically used as a way to preprocess data for SurvivalDistribution when data is provided with a separate censoring vector.
  • The following censoring types c can be used in Censoring[t,c]:
  • 0, None{t,t}no censoring
    1, Right{t,}right-censoring
    -1,Left{-,t}left-censoring

Examples

open allclose all

Basic Examples  (2)Summary of the most common use cases

Use with right-censored data in SurvivalDistribution:

Out[2]=2
Out[3]=3

Convert tables with censoring indicators to interval notation:

Out[2]=2

Scope  (6)Survey of the scope of standard use cases

Convert a right-censored observation to interval notation:

Out[2]=2

Alternatively, use Right:

Out[3]=3

Work with left-censored observations:

Out[2]=2

Alternatively, use Left:

Out[3]=3

The observation is unchanged in the absence of censoring:

Out[2]=2

You can also specify no censoring as None:

Out[3]=3

Thread a single censoring indicator over a list of events:

Out[2]=2

Use a mix of censoring indicators:

Out[3]=3

Interval-censored observations are converted as well:

Out[2]=2

Possible Issues  (1)Common pitfalls and unexpected behavior

A dataset of length 2 is treated as a single interval-censored observation:

One right-censored observation results in:

Out[2]=2

If two observations were intended, use two indicators:

Out[3]=3
Wolfram Research (2010), Censoring, Wolfram Language function, https://reference.wolfram.com/language/ref/Censoring.html.
Wolfram Research (2010), Censoring, Wolfram Language function, https://reference.wolfram.com/language/ref/Censoring.html.

Text

Wolfram Research (2010), Censoring, Wolfram Language function, https://reference.wolfram.com/language/ref/Censoring.html.

Wolfram Research (2010), Censoring, Wolfram Language function, https://reference.wolfram.com/language/ref/Censoring.html.

CMS

Wolfram Language. 2010. "Censoring." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/Censoring.html.

Wolfram Language. 2010. "Censoring." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/Censoring.html.

APA

Wolfram Language. (2010). Censoring. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Censoring.html

Wolfram Language. (2010). Censoring. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Censoring.html

BibTeX

@misc{reference.wolfram_2025_censoring, author="Wolfram Research", title="{Censoring}", year="2010", howpublished="\url{https://reference.wolfram.com/language/ref/Censoring.html}", note=[Accessed: 06-June-2025 ]}

@misc{reference.wolfram_2025_censoring, author="Wolfram Research", title="{Censoring}", year="2010", howpublished="\url{https://reference.wolfram.com/language/ref/Censoring.html}", note=[Accessed: 06-June-2025 ]}

BibLaTeX

@online{reference.wolfram_2025_censoring, organization={Wolfram Research}, title={Censoring}, year={2010}, url={https://reference.wolfram.com/language/ref/Censoring.html}, note=[Accessed: 06-June-2025 ]}

@online{reference.wolfram_2025_censoring, organization={Wolfram Research}, title={Censoring}, year={2010}, url={https://reference.wolfram.com/language/ref/Censoring.html}, note=[Accessed: 06-June-2025 ]}