{'fraction_non_alphanumeric': 0.04548556276929676, 'fraction_numerical': 0.01959408083289466, 'mean_word_length': 4.528942546081708, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 2, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 9, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
The wild bootstrap for multivariate Nelson–Aalen estimators

We rigorously extend the widely used wild bootstrap resampling technique to the multivariate Nelson–Aalen estimator under Aalen’s multiplicative intensity model. Aalen’s model covers general Markovian multistate models including competing risks subject to independent left-truncation and right-censoring. This leads to various statistical applications such as asymptotically valid confidence bands or tests for equivalence and proportional hazards. This is exemplified in a data analysis examining the impact of ventilation on the duration of intensive care unit stay. The finite sample properties of the new procedures are investigated in a simulation study.

function, also known as cumulative transition intensity. Most commonly, it is nonparametrically estimated by the well-known Nelson-Aalen estimator (Andersen et al. 1993, Chapter IV). In this context, time-simultaneous confidence bands are the perhaps best interpretative tool to account for related estimation uncertainties.
The construction of confidence bands is typically based on the asymptotic behavior of the underlying stochastic processes, more precisely, the (properly standardized) Nelson-Aalen estimator asymptotically behaves like a Wiener process. Early approaches utilized this property to derive confidence bands for the cumulative hazard function; see e.g., Bie et al. (1987) or Section IV.1.3 in Andersen et al. (1993).
However, Dudek et al. (2008) found that this approach applied to small samples can result in considerable deviations from the nominal level. To improve small sample properties, Efron (1979Efron ( , 1981 suggested a computationally convenient and flexible resampling technique, called bootstrap, where the unknown non-Gaussian quantile is approximated via repeated generation of point estimates based on random samples of the original data. For a detailed discussion within the standard right-censored survival setup, see also Akritas (1986), Lo and Singh (1986), and Horvath and Yandell (1987). The simulation study of Dudek et al. (2008) particularly reports improvements of bootstrap-based confidence bands for the hazard function as compared to those using asymptotic quantiles. An alternative is the so-called wild bootstrap firstly proposed in the context of regression analyses (Wu 1986). As done in Lin et al. (1993), the basic idea is to replace the (standardized) residuals with independent standardized variates-so-called multipliers-while keeping the data fixed. One advantage compared to Efron's bootstrap is to gain robustness against variance heteroscedasticity (Wu 1986). Using standard normal multipliers, this resampling procedure has been applied to construct time-simultaneous confidence bands for survival curves under the Cox proportional hazards model (Lin et al. 1994) and adapted to cumulative incidence functions in the competing risks setting (Lin 1997). The latter approach has recently been extended to general wild bootstrap multipliers with mean zero and variance one , which indicate possible improved small sample performances. This result was confirmed in Dobler and Pauly (2014) as well as Dobler et al. (2017), where more general resampling schemes are discussed. In all these references, only one multiplier, typically standard normal, was required per individual, because each individual experienced at most one event. If an individual may experience more than one event, multiple multipliers per individual were, e.g., considered by Dabrowska and Ho (2000) in the context of Cox modelling, see also Shu et al. (2007) for Cox models in a semi-Markov illness-death model, and Liu et al. (2008) in a progressive multistate model for current leukemia free survival.
The present article focuses on the nonparametric estimation of cumulative hazard functions and proposes a general and flexible wild bootstrap resampling technique, which is valid for a large class of time-to-event models. In particular, the procedure is not limited to the standard survival or competing risks framework. The key assumption is that the involved counting processes satisfy the so-called multiplicative intensity model (Andersen et al. 1993). Consequently, arbitrary Markovian multistate models with finite state space are covered, as well as various other intensity models (e.g., excess or relative mortality models, cf. Andersen and Vaeth 1989) and specific semi-Markov situations (Andersen et al. 1993, Example X.1.7). Independent right-censoring and left-truncation can straightforwardly be incorporated.
The main aim of this article is to mathematically justify the wild bootstrap technique for the multivariate Nelson-Aalen estimator in this general framework, while using not necessarily normally distributed but possibly multiple multipliers per counting process in the resampling step, This is accomplished by a novel martingale-based proof that discloses the close connection between the estimator and its wild bootstrap version. This insight would not have been possible by generalizing the elementary approach for showing bootstrap validity in competing risks given in Beyersmann et al. (2013) and Dobler and Pauly (2014) to the present set-up. Compared to the standard survival or competing risks setting, with at most one transition per individual, the major difficulty is to account for counting processes having an arbitrarily large random number of jumps. We will see that utilizing only one multiplier per individual counting process leads to the wrong covariance structure in general; instead, one multiplier per increment is required. As Beyersmann et al. (2013) suggested in the competing risks setting, we also allow for more general multipliers with expectation 0 and variance 1 and extend the resulting weak convergence theorems to resample the multivariate Nelson-Aalen estimator in our general setting. For practical applications, this result allows, for instance, within-or two-sample comparisons and the formulation of statistical tests.
The wild bootstrap is exemplified to statistically assess the impact of mechanical ventilation in the intensive care unit (ICU) on the length of stay. A related problem is to investigate ventilation-free days, which was established as an efficacy measure in patients subject to acute respiratory failure (Schoenfeld et al. 2002). However, applications of their methodology (see e.g., Sauaia et al. 2009;Stewart et al. 2009) rely on the constant hazards assumption. Other publications like de Wit et al. (2008), Trof et al. (2012), or Curley et al. (2015 used a Kaplan-Meier-type procedure that does not account for the more complex multistate structure. In contrast, we propose an illnessdeath model with recovery that methodologically works under the more general timeinhomogeneous Markov assumption and captures both the time-dependent structure of mechanical ventilation and the competing endpoint 'death in ICU'. The remainder of this article is organized as follows: Sect. 2 introduces cumulative hazard functions and their Nelson-Aalen estimators using counting process formulations. After summarizing its asymptotic properties, Sect. 3 offers our main theorem on conditional weak convergence for the wild bootstrap. This allows for various statistical applications in Sect. 4: Two-sided hypothesis tests and various sorts of time-simultaneous confidence bands are deduced, as well as simultaneous confidence intervals for a finite set of time points. Furthermore, tests for equivalence, inferiority and superiority as well as for proportionality of two hazard functions constitute useful criteria in practical data analyses. A simulation study assessing small and large sample performances of both the derived confidence bands in comparison to the algebraic approach based on the time-transformed Brownian motion and the tests for proportional hazards is reported in Sect. 5. The SIR-3 data on patients in ICU (Beyersmann et al. 2006;Wolkewitz et al. 2008) serves as its template and is practically revisited in Sect. 6. Concluding remarks and a discussion are given in Sect. 7. All proofs are deferred to Appendix A and the non-applicability of the ordinary multiplier resampling is verified in Appendix B.

Nonparametric estimation under the multiplicative intensity structure
Throughout, we adopt the notation of Andersen et al. (1993). For k ∈ N, let N = (N 1 , . . . , N k ) be a multivariate counting process which is adapted to a filtration (F t ) t≥0 . Each entry N j , j = 1, . . . , k, is supposed to be a càdlàg function, zero at time zero, and to have piecewise constant paths with jumps of size one. In addition, assume that no two components jump at the same time and that each N j (t) satisfies the multiplicative intensity model of Aalen (1978) with intensity process given by λ j (t) = α j (t)Y j (t). Here, Y j (t) defines a predictable process not depending on unknown parameters and α j describes a non-negative (hazard) function. For well-definiteness, the observation of N is restricted to the interval [0, τ ], where τ < τ j = sup u ≥ 0 : (0,u] α j (s)ds < ∞ for all j = 1, . . . , k. The multiplicative intensity structure covers several customary frameworks in the context of time-to-event analysis. The following overview specifies frequently used models.
Example 1 (a) Markovian multistate models with finite state space S are very popular in biostatistics. In this setting, Y (t) represents the total number of individuals in state just prior to t ('number at risk'), whereas α m (t) is the instantaneous risk ('transition intensity') to switch from state to m, where , m ∈ S, = m. Here, N = n i=1 N ;i is the aggregation over individual-specific counting processes with n ∈ N individuals under study. For specific examples (such as competing risks or the illness-death model) and details including the incorporation of independent left-truncation and right-censoring, see Andersen et al. (1993) and Aalen et al. (2008). (b) Other examples are the relative or excess mortality model, where not all individuals necessarily share the same hazard rate α. In this case Y cannot be interpreted as the total number of individuals at risk as in part (a); see Example IV.1.11 in Andersen et al. (1993) for details. (c) The time-inhomogeneous Markov assumption required in part (a) can even be relaxed in specific situations: Following Example X.1.7 in Andersen et al. (1993), consider an illness-death model without recovery. Assuming that the transition intensity α 12 depends on the duration d in the intermediate state, but not on time t, leads to a semi-Markov process not satisfying the multiplicative intensity structure. This is because the intensity process of N 12 (t) is given by where the first factor of the product is not deterministic anymore. Here, T is the random transition time into state 1. However, when d = t − T is used as the basic timescale, the counting process Thus, the multiplicative intensity structure is fulfilled. Under the above assumptions, the Doob-Meyer decomposition applied to N j leads to where the M j are zero-mean martingales with respect to (F t ) t∈ [0,τ ] . The canonical nonparametric estimator of the cumulative hazard function A j (t) = (0,t] α j (s)ds is given by the so-called Nelson-Aalen estimator Here, J j (t) = 1{Y j (t) > 0}, 0 0 := 0, and n ∈ N is a sample size-related number (that goes to infinity in asymptotic considerations). Its multivariate counterpart is introduced byÂ n := (Â 1n , . . . ,Â kn ) . As in Andersen et al. (1993), suppose that there exist deterministic functions y j with inf u∈ [0,τ ] where ' P →' denotes convergence in probability for n → ∞. For each j, define the normalized Nelson-Aalen process W jn := √ n(Â jn − A j ) possessing the asymptotic martingale representation with M j given by (2.1). Here, ' ' means that the difference of both sides converges to zero in probability. Define the vectorial aggregation of all W jn as W n = (W 1n , . . . , W kn ) and let ' d →' denote convergence in distribution for n → ∞. Then, Theorem IV.1.2 in Andersen et al. (1993) in combination with (2.2) provides a weak convergence result on the k-dimensional space D[0, τ ] k of càdlàg functions endowed with the product Skorohod topology.
The covariance function ψ j is commonly approximated by the Aalen-typê (2.5) or the Greenwood-type estimator which are consistent for ψ j (s 1 , s 2 ) under the assumption of Theorem 1; cf. (4.1.6) and (4.1.7) in Andersen et al. (1993). Here, ΔN j (s) denotes the jump size of N j at time s.

Inference via Brownian bridges and the wild bootstrap
As discussed in Andersen et al. (1993), the limit process U can analytically be approximated via Brownian bridges. However, improved coverage probabilities in the simulation study in Sect. 5 suggest that the proposed wild bootstrap approach may be preferable. First, we sum up the classic result.

Inference via transformed Brownian bridges
The asymptotic mutual independence stated in Theorem 1 allows to focus on a single component of W n , say W 1n = √ n(Â 1n − A 1 ). For notational convenience, we suppress the subscript 1. Let g be a positive (weight) function on an interval [t 1 , t 2 ] ⊂ [0, τ ] of interest and B 0 a standard Brownian bridge process. Then, as n → ∞, it is established in Section IV.1 in Andersen et al. (1993) Here φ(t) = σ 2 (t) 1+σ 2 (t) , σ 2 (t) = ψ(t, t) andσ 2 (t) is a consistent estimator for σ 2 (t), such as (2.5) or (2.6). Quantiles of the right-hand side of (3.1) for g ≡ 1 are recorded in tables (e.g., Koziol and Byar 1975;Hall and Wellner 1980;Schumacher 1984). For general g, they can be approximated via standard statistical software.
Even though relation (3.1) enables statistical inference based on the asymptotics of a central limit theorem, appropriate resampling procedures usually showed improved properties; see e.g., Hall and Wilson (1991), Good (2005) and Pauly et al. (2015).

Wild bootstrap resampling
In contrast to, for instance, a competing risks model where each counting process N j is at most n, the number N j (τ ) is not necessarily bounded in our setup only assuming Aalen's multiplicative intensity model. Hence, a modification of the multiplier resampling scheme under competing risks suggested by Lin (1997) and elaborated by Beyersmann et al. (2013) is required. For this purpose, introduce counting processspecific stochastic processes indexed by s ∈ [0, τ ] that are independent of N j , Y j for all j = 1, . . . , k. Let (G j (s)) s∈ [0,τ ] , 1 ≤ j ≤ k, be independently and identically distributed (i.i.d.) white noise processes such that each G j (s) satisfies E(G j (s)) = 0 and var(G j (s)) = 1, j = 1, . . . , k, s ∈ [0, τ ]. That is, all -dimensional marginals of G 1 , ∈ N, shall be the same -fold product-measure. Then, a wild bootstrap version of the normalized multivariate Nelson-Aalen estimator W n is defined aŝ In words,Ŵ n is obtained from representation (2.3) of W n by substituting the unknown individual martingale processes M j with the observable quantities G j N j . Even though only the values of each G j at the jump times of N j are relevant, this construction in terms of white noise processes enables a consideration of the wild bootstrap process on a product probability space; see the Appendix for details. Consider for a moment the special case of a multistate model with n i.i.d. individuals (Example 1(a)). For instance, the competing risks model in Lin (1997) involves at most one transition (and thus one multiplier) per individual, while Glidden (2002) introduces only one multiplier per individual for estimating state occupation probabilities in general non-Markov multistate models. In contrast, our resampling approach is a new approach in the sense that it involves independent weightings of all jumps even within the same individual. The consequence is that, instead of considering one multiplier per individual, we need to utilize a white noise processes as done in (3.2) in order to account for randomly many numbers of events per individual.
The limit distribution ofŴ n may be approximated by simulating a large number of replicates of the G's, while the data is kept fixed. For a competing risks setting with standard normally distributed multipliers, our general scheme reduces to the one discussed in Lin (1997).
For the remainder of the paper, we summarize the available data in the σ -algebra A natural way to introduce a filtration based on C 0 that progressively collects information on the white noise processes is by setting The following lemma is a key argument in an innovative, martingale-based consistency proof of the proposed wild bootstrap technique.
Lemma 1 For each n ∈ N, the wild bootstrap version of the multivariate Nelson-Aalen estimator (Ŵ n (t)) t∈[0,τ ] is a square-integrable martingale with respect to the filtration (C t ) t∈[0,τ ] with orthogonal components. Its predictable variation process is given by and its optional variation process by The following conditional weak convergence result justifies the approximation of the limit distribution of W n viaŴ n given C 0 . Both, the general framework requiring only Aalen's multiplicative intensity structure as well as using possibly non-normal multipliers are original to the present paper.
Theorem 2 Let U be as in Theorem 1. Assuming (2.2), we have the following conditional convergence in distribution on D[0, τ ] k given C 0 as n → ∞: Remark 1 (a) Reconsider the ordinary multiplier resampling based on a sequence of (time-constant) i.i.d. random variables D 1 , . . . , D n with E(D 1 ) = 0 and unit variance where, in the resampling step, the martingales M j are replaced with D j N j . In contrast to the wild bootstrap based on white noise processes, the wild bootstrap using the time-constant sequence D 1 , . . . , D n fails to reproduce the correct covariance structure of the Nelson-Aalen process. Even in the special univariate Markovian case, the limit process does not have independent increments and it hence necessarily differs from the asymptotics described in Theorem 2; see Appendix B for details. (b) It is due to the martingale property of the wild bootstrapped multivariate Nelson-Aalen estimator that we anticipate a good finite sample approximation of the unknown distribution of the Nelson-Aalen estimator. In particular, the wild bootstrap, realized by white noise processes as above, succeeds in imitating the martingale structure of the original Nelson-Aalen estimator. The predictable variation process of the wild bootstrap process equals the optional variation process of the centered Nelson-Aalen process. Hence, both processes share the same properties and approximately the same covariance structure.
, which for example holds for any k ∈ N if Y 1 has a number at risk interpretation. Since different increments of W n (to arbitrary powers) are uncorrelated, it can be shown that the convergence in Theorem 1 for single t ∈ [0, τ ] even holds in the Mallows metric d p for any 0 < p ≤ k; see, for instance, Bickel and Freedman (1981) for such theorems related to the classical bootstrap. Provided that the r th moment of G 1 (u) exists, similar arguments show that the convergence in probability in Theorem 2 for single t ∈ [0, τ ] holds in the Mallows metric d p for any even 0 < p ≤ r as well. This of course includes white noise processes with centered Poi(1) or standard normal marginals, as applied later on.

Statistical applications
Throughout this section denote by α ∈ (0, 1) the nominal level of all inference procedures.

Confidence bands
After having established all required weak convergence results, we discuss different possibilities for realizing confidence bands for A j around the Nelson-Aalen estimator Later on, we propose a confidence band for differences of cumulative hazard functions. As in Sect. 3.1, we first focus on A 1 and suppress the index 1 for notational convenience. Following Andersen et al. (1993), Section IV.1, we consider weight functions as choices for g in relation (3.1). The resulting confidence bands are commonly known as equal precision and Hall-Wellner bands, respectively. We apply a logtransformation in order to improve small sample level α control. Combining the previous sections' convergences with the functional delta-method and Slutsky's lemma yields conditionally given C 0 in probability, with φ as in Sect. 3 and the wild bootstrap variance estimator σ * 2 (s) In particular, σ * 2 is a uniformly consistent estimate for σ 2 (Dobler and Pauly 2014) and, being the optional variation process of the wild bootstrap Nelson-Aalen process, it may be one natural choice for variance estimation. For practical purposes, we adapt the approach of Beyersmann et al. (2013) and estimate σ 2 based on the empirical variance of the wild bootstrap quantitiesŴ n . The continuity of the supremum functional translates (4.1) and (4.2) into weak convergences for the corresponding suprema. Hence, the consistency of the following critical values is ensured: where L(·) denotes the law of a random variable. Here, g equals either g 1 or g 2 andφ =σ 2 1+σ 2 . Note, thatc g 1−α is, in fact, a random variable. The results are backtransformed into four confidence bands for A abbreviated with HW and EP for the Hall-Wellner and equal precision bands and a and w for bands based on quantiles of the asymptotic distribution and the wild bootstrap, respectively. In our simulation studies these bands are also compared with the linear confidence band C B w dir , which is based on the critical valuẽ Corollary 1 Under the assumptions of Theorem 3, the following bands for the cumulative hazard function (A(s)) s∈[t 1 ,t 2 ] provide an asymptotic coverage probability of 1 − α: Remark 2 1. Note that the wild bootstrap quantilec 1−α does not require an estimate of φ, thereby eliminating one possible cause of inaccuracy within the derivation of the other bands. However, the corresponding band CB w dir has the disadvantage to possibly include negative values. 2. The confidence bands are only well-defined if the left endpoint t 1 of the bands' time interval is larger than the first observed event. In particular, these bands yield unstable results for small values ofÂ n (t 1 ) due to the division in the exponential function; see Lin et al. (1994) for a similar observation. 3. The present approach directly allows the construction of confidence bands for within-sample comparisons of multiple A 1 , . . . , A k . For instance, a confidence band for the difference A 1 − A 2 may be obtained via quantiles based on the conditional convergence in distributionŴ 1n −Ŵ 2n d −→ U 1 −U 2 ∼ Gauss(0, ψ 1 +ψ 2 ) in probability by simply applying the continuous mapping theorem and taking advantage of the independence of U 1 and U 2 ; see Whitt (1980) for the continuity of the difference functional. For that purpose, the distribution of with positive weight function g can be approximated by the conditional distribution Similar arguments additionally enable common two-sample comparisons. A practical data analysis using other weight functions g in the context of cumulative incidence functions is given in Hieke et al. (2013).

Remark 3 (Construction of confidence intervals)
1. In particular, Theorem 3 yields a convergence result on R m for a finite set of time points Hence, using critical valuesc 1−α andc g 1−α obtained from the law of the maximum max s 1 ,...,s m instead of the supremum, a variant of Corollary 1 specifies simultaneous confidence intervals I 1 × · · · × I m for (A(s 1 ), . . . , A(s m )) with asymptotic coverage probability 1−α. Since the error multiplicity is taken into account, the asymptotic coverage probability of a single such interval I j for A(s j ) is greater than 1 − α. 2. Due to the asymptotic independence of the entries of the multivariate Nelson-Aalen estimator, a confidence region for the value of a multivariate cumulative hazard function (A 1 (t), . . . , A k (t)) at time t ∈ [0, τ ] may be found using Šidák's correction: Letting J 1 , . . . , J k be pointwise confidence intervals for A 1 (t), . . . , A k (t) with asymptotic coverage probability (1 − α) 1/k , each found using the wild bootstrap principle, the coverage probability of J 1 ×· · ·× J k for A 1 (t)×· · ·× A k (t) clearly goes to 1 − α as n → ∞.

Hypothesis tests for equivalence, inferiority, superiority, and equality
Adapting the principle of confidence interval inclusion as discussed in Wellek (2010) Corollary 2 Under the assumptions of Theorem 3, a hypothesis test ψ n of asymptotic level α for H vs K is given by the following decision rule: Reject H if and only if the combined two-sided confidence band (a n (s), b n (s)) s∈[t 1 ,t 2 ] is fully contained in the region spanned by . Further, it holds under K that E(ψ n ) → 1 as n → ∞, i.e., ψ n is consistent.
Similar arguments lead to analogue one-sided tests for the inferiority or superiority of the true cumulative hazard function to a prespecified function A 0 . Moreover, statistical tests for equality of two cumulative hazard functions can be constructed using the weak convergence results of Remark 2(c): Corollary 3 below yields an asymptotic level α test for H = . Bajorunaite and Klein (2007) and Dobler and Pauly (2014) used similar two-sided tests for comparing cumulative incidence functions in a two-sample problem.

Corollary 3 (A Kolmogorov-Smirnov-type test)
Under the assumptions of Theorem 3 and letting g again be a positive weight function, Similarly, Theorem 3 enables the construction of other tests, e.g., such of Cramér-von Mises-type. Furthermore, by taking the suprema over a discrete set {s 1 , . . . , s m } ⊂ [0, τ ], the Kolmogorov-Smirnov test of Corollary 3 can also be used to test Note that in a similar way, two-sample extensions of Corollaries 2 and 3 can be established following Dobler and Pauly (2014).

Tests for proportionality
A major assumption of the widely used Cox (1972) regression model is the assumption of proportional hazards over time. Several authors have developed procedures for testing the null hypothesis of proportionality, see e.g., Gill and Schumacher (1987), Lin (1991), Grambsch and Therneau (1994), Hess (1995), Scheike and Martinussen (2004), Kraus (2007), Bagdonavičius et al. (2010), or Chen et al. (2015, and the references cited therein. However, most of these approaches have mainly been investigated for the standard survival framework under (independent) right-censoring and left-truncation mechanisms, even though they may be generalized to more general settings. In the context of the proposed wild bootstrap resampling technique, this motivates the explicit formulation of a two-sample proportionality test for the general setting only assuming a multiplicative intensity structure. This covers, for instance, arbitrary Markovian multistate models. The framework is an unpaired two-sample model given by independent counting processes N (1) , N (2) and predictable processes Y (1) , Y (2) , assuming the conditions of Sect. 2 for each group, and with sample sizes n 1 and n 2 , respectively. Let again N ( j) the Nelson-Aalen estimator of the cumulative hazard functions A ( j) and by α ( j) the corresponding rates, j = 1, 2. To motivate a suitable test statistic we make use of the following equivalence between hazards proportionality and equality of both cumulative hazards: which, as the null hypothesis of interest, is denoted by H 0,prop . In a natural way, similar to Gill and Schumacher (1987), this leads to statistics of the form

Simulation study
The motivating example behind the present simulation study is the SIR-3 data of Sect. 6. The setting is a specification of Example 1(a) called illness-death model with recovery. As illustrated in the multistate pattern of Fig. 1, the model has state space S = {0, 1, 2} and includes the transition hazards α 01 , α 10 , α 02 , and α 12 . The simulation of the underlying quantities is based on the methodology suggested by Allignol et al. (2011) generalized to the time-inhomogeneous Markovian multistate framework, which can be seen as a nested series of competing risks experiments. More precisely, the individual initial states are derived from the proportions of individuals at t = 0 and the censoring times are obtained from a multinomial experiment using probability masses equal to the increments of the censoring Kaplan-Meier estimate originated from the SIR-3 data. Similarly, event times are generated according to a multinomial distribution with probabilities given by the increments of the original Nelson-Aalen estimators. These times are subsequently included into the multistate simulation algorithm described in Beyersmann et al. (2012), Section 8.2. Since censoring times are sampled independently and each simulation step is only based on the current time and the current state, the resulting data follows a Markovian structure. A more formal justification of the multistate simulation algorithm can be found in Gill and Johansen (1990) and Theorem II.6.7 in Andersen et al. (1993).
We consider three different sample sizes: The original number of 747 patients is stepwisely reduced to 373, 186, and 93 patients. For each scenario we simulate 1000 studies. As an overview, the mean number of events for each possible transition and scenario is illustrated in Table 1.
The mean number of events regarding 747 patients reflects the original number of events. All numbers are restricted to the time interval [5,30], which is chosen due to a small amount of events before t = 5 (left panel of Fig. 2). Further, less than 10% of all individuals are still under observation after day 30. In particular, asymptotic approximations tend to be poor at the left-and right-hand tails; cf. Remark 2(b) and Lin (1997).
Utilizing the R-package sde (Iacus 2014), the quantiles c g 1−α in (4.3) of each single study are empirically estimated by simulating 1000 sample paths of a standard Brownian bridge. These quantiles are separately derived for both the Aalenand Greenwood-type variance estimates (2.5) and (2.6). The bootstrap critical values are based on 1000 bootstrap realizations ofŴ n for each simulation step including both standard normal and centered Poisson variates with variance one. The latter is motivated by a slightly better performance compared to standard normal multipliers Dobler et al. 2017). Furthermore, Liu (1988) argued in a classical (linear regression) problem that wild bootstrap weights with skewness equal to one satisfy the second order correctness of the resampling approach. According to the cited simulation results, a similar result might hold true in our context, as the Poisson variates have skewness equal to one and standard normal variates are symmetric. A careful analysis of the convergence rates, however, is certainly beyond the scope of this article. In order to guarantee statistical reliability, we do not derive confidence bands for sample sizes and transitions with a mean number of observed transitions distinctly smaller than 20. The nominal level is set to α = 0.05. All simulations are performed with the R-computing environment version 3.3.2 (R Core Team 2016).
Following Table 2, almost all bands constructed via Brownian bridges consistently tend to be rather conservative in our setting, i.e., result in too broad bands. Here, the usage of the Greenwood-type variance estimate yields more accurate coverage probabilities compared to the Aalen-type estimate. In contrast, the wild bootstrap approach mostly outperforms the Brownian bridge procedures: The log-transformed wild bootstrap bands approximately keep the nominal level even in the smaller sample sizes, except for the 0 → 1 transition with smallest sample size (corresponding to only 17 events in the mean; cf. Table 1). We also observe that the log-transformation For that purpose, we assume a competing risks model with two competing events separately for two unpaired patient groups. For an illustration, see for instance, Figure  3.1 in Beyersmann et al. (2012).
We consider four different constant hazard scenarios: (I) the hazards for the type-1 event are set to α (1) 01 (t) = 2 (no effect on the type-1 hazard, in particular, a hazard ratio of c = 1); (II) α 02 (t) = 2, in particular, we consistently assume no group effect on the competing hazard. Further, scenario-specific administrative censoring times are chosen such that approximately 25% of the individuals are censored. The simulations designs are selected such that we include different effect sizes as well as different type-1 hazard ratio configurations with respect to the competing hazards. We consider a balanced design with n 1 = n 2 = n ∈ {125, 250, 500, 1000}. The right-hand tail of the domain of interest is set to τ = 0.3. Simulation of the event times and types follows the procedure explained in Chapter 3.2 of Beyersmann et al. (2012). As before, we simulate 1000 studies for each scenario and sample size configuration, whereas the critical values of the Kolmogorov-Smirnov-type and Cramér-von-Mises-type statistics from Sect. 4.3 are derived from 1000 bootstrap samples utilizing both standard normal and centered Poisson variates with variance one.
The results for the type I error rates (for α = 0.05) are displayed in Table 3. As expected from consistency, the type I error control becomes better with a larger number of patients for both test statistics in each scenario. Except for Scenario (II), all procedures keep the type I error rate quite accurately for n ≥ 500. For smaller sample sizes, all tests tend to be conservative with a particular advantage for the Kolmogorov-Smirnov statistic.

Data example
The SIR-3 (Spread of Nosocomial Infections and Resistant Pathogens) cohort study at the Charité University Hospital in Berlin, Germany, prospectively collected data on the occurrence and consequences of hopital-aquired infections in intensive care (Beyersmann et al. 2006;Wolkewitz et al. 2008). A device of particular interest in critically ill patients is mechanical ventilation. The present data analysis investigates the impact of ventilation on the length of intensive care unit stay which is, e.g., of interest in cost-benefit analyses in hospital epidemiology .  The analysis considers a random subset of 747 patients of the SIR-3 data which one of us has made publicly available (Beyersmann et al. 2012). Patients may either be ventilated (state 1 as in Fig. 1) or not ventilated (state 0) upon admission. Switches in device usage are modeled as transitions between the intermediate states 0 and 1. Patients move into state 2 upon discharge from the unit. The numbers of observed transitions are reported in the last row of Table 1. We start by separately considering the two cumulative end-of-stay hazards A 12 and A 02 , followed by a more formal group comparison as in Remark 2(c). Based on the approach suggested by Beyersmann et al. (2012), Section 11.3, we find it reasonable to assume the Markov property. Figure 2 displays the Nelson-Aalen estimates of A 12 and A 02 accompanied by simultaneous 95% confidence bands utilizing the 1000 wild bootstrap versions with standard normal variates and restricted to the time interval [5,30] of intensive care unit days. As before, the left-hand tail of the interval is chosen, because Nelson-Aalen estimation regarding A 12 picks up at t = 5, cf. the left panel of Fig. 2. Graphical validation of empirical means and variances ofŴ n showed good compliance compared to the theoretical limit quantities stated in Remark 1. Bands using Poisson variates are similar (both results not shown). Figure 3 also displays the 95% pointwise confidence intervals based on a log-transformation. The performance of both equal precision and Hall-Wellner bands is comparable for transitions out of the ventilation state. However, the latter tend to be larger for the 0 → 2 transitions for later days due to more unstable weights at the right-hand tail. Equal precision bands are graphically competitive when compared to the pointwise confidence intervals. Ventilation significantly reduces the hazard of end-of-stay, since the upper half-space is not contained in the 95% confidence band of the cumulative hazard difference, see Fig. 4. A second investigation exemplary applies the nonparametric proportionality test suggested in Sect. 4.3 to the present study example. For that purpose, we consider sex-specific subsamples (441 male vs. 306 female patients) and test H 0,prop using both the Kolmogorov-Smirnov-and the Cramér-von-Mises-type test statistic. The Fig. 4 95% confidence bands from relation (4.5) based on standard normal multipliers and 95% linear pointwise confidence intervals for difference of the two cumulative hazards of end-of-stay from the data example in Sect. 6. The solid black lines is the difference 'ventilation vs. no ventilation' of the Nelson-Aalen estimators within the two ventilation groups Nelson-Aalen estimators separately displayed for males and females are given in Supplementary Figure S1. p values are computed from 1000 bootstrap samples utilizing standard normal variates and the right-hand limit of the interval of interest is set to 30 days. Tabulated results are in Supplementary Table S1 including the test statistics T n 1 ,n 2 and the bootstrap quantilesq 0.95 of Theorem 4 as well as the corresponding bootstrap p valuesp. Non-proportionality cannot be inferred for any of the transitions at the 5% level.
A concise R-script is available in the online supplementary material, which executes the bootstrap core operation given in relation (3.2) in a computationally efficient way.

Discussion and further research
We have given a rigorous presentation of a weak convergence result for the wild bootstrap methodology for the multivariate Nelson-Aalen estimator in a general setting only assuming Aalen's multiplicative intensity structure of the underlying counting processes. This allowed the construction of time-simultaneous confidence bands and intervals as well as asymptotically valid equivalence and equality tests for cumulative hazard functions. In the context of time-to-event analysis, our general framework is not restricted to the standard survival or competing risks setting, but also covers arbitrary Markovian multistate models with finite state space, other classes of intensity models like relative survival or excess mortality models, and even specific semi-Markov situations. Additionally, independent left-truncation and right-censoring can be incor-porated. The procedure has also been used to construct a test for proportional hazards. We want to emphasize that the framework induces a random number of multipliers in relation (3.2); thus, goes beyond existing approaches for competing risks as done in Beyersmann et al. (2013) or Lin (1997). Easy and computationally convenient implementation and within-or two-sample comparisons demonstrate its attractiveness in various practical applications.
Future work will be on the approximation of the asymptotic distribution corresponding to the matrix of transition probabilities (see Aalen and Johansen 1978) and functionals thereof in general Markovian multistate models. This is of great practical interest, because no similar Brownian Bridge procedure is available to perform time-simultaneous statistical inference. In particular, previous implications rely on pointwise considerations. Note that such an approach would significantly simplify the original justifications given by Lin (1997) and generalizes his idea mainly used in the context of competing risks (Scheike and Zhang 2003;Hyun et al. 2009;Beyersmann et al. 2013). In addition, we plan to extend the utilized wild bootstrap technique to general semiparametric regression models; see Lin et al. (2000) for an application in the survival context. Current work investigates to what degree the martingale properties presented in this article may be exploited to obtain wild bootstrap consistencies for such functionals of Nelson-Aalen estimates or for estimators in semiparametric regression models. We are confident that the present approach will lead to reliable inference procedures in these contexts for which there has been only little research on such general methodology.
In contrast to the procedure of Schoenfeld et al. (2002) or the framework in Cube et al. (2017), the more general illness-death model with recovery does not rely on a constant hazards assumption and captures both the time-dependent structure of mechanical ventilation and the competing event 'death in ICU'. This significantly improves medical interpretations. The widths of the confidence bands were competitive compared to the pointwise confidence intervals, i.e., demonstrated usefulness in practical situations.
In the present data analysis, the multistate perspective is the natural way to assess the impact of time-dependent exposures on complex survival outcomes. This is a current topic in various fields of applied research; thus, the wild bootstrap procedure in its very general formulation is practicable to analyses regarding, for instance, different stages of illicit drug use (Mayet et al. 2012), the clinical course of liver diseases (Jepsen et al. 2015), antibiotics in hospital epidemiology (Munoz-Price et al. 2016), alternative outcomes in leukemia trials (Schmoor et al. 2013;Eefting et al. 2016), or joint replacements in orthopaedic patients (Gillam et al. 2012). It has even been recently applied in a study investigating femoral fracture risk, disability, and mortality in an elderly population (Bluhmki et al. 2017).
It has to be emphasized that our simulation study suggested that the wild bootstrap approach leads to more powerful procedures (i.e., to narrower confidence bands) compared to the approximation via Brownian bridges. As expected, the applied log-transformation results in improved small sample properties compared to the untransformed wild bootstrap bands. Based on the current simulation study, however, it was difficult to clearly recommend which type of band and which type of multiplier should be used.
again by the C s -measurability of G(u) for u ≤ s and their independence for u > s. The second to last equality is due to the independence of G(u) and is a martingale. Letting Δf denote the jump-size process fo a càdlàg function f , the definition of the optional variation process yields where the sum is taken over all jump points of N .
Proof (of Theorem 2) : It is enough to verify the conditions of Rebolledo's martingale central limit theorem (in conditional probability); see e.g., Theorem II.5.1 in Andersen et al. (1993). Since the filtration C 0 at time s = 0 is not trivial, the resulting weak convergence will hold given C 0 as well, in probability. From the classical theory we know that the Aalen-type variance estimator, which is in fact the predictable variation process ofŴ n , is uniformly consistent for the variance function. It remains to prove the Lindeberg condition (2.5.3) on page 83 in Andersen et al. (1993). But, by the same arguments as in the proof of Lemma 1, this is exactly the same as the Lindeberg condition for the Nelson-Aalen estimator itself. And this holds due to the main assumption (2.2).
Hence, Rebolledo's martingale central limit theorem yields the desired weak convergence as well as the uniform consistency of the optional variation process.
Proof (of Corollaries 1 and 3) : Due to the continuous limit distribution the conditional quantiles converge as well in probability; see e.g., Janssen and Pauls (2003), Lemma 1. The consistency of ϕ K S n under K = follows from the convergence in probability of the conditional quantile towards a finite value and from the uniform consistency of the multivariate Nelson-Aalen estimator for the cumulative hazard functions. Since the factor √ n tends to infinity, the test statistic also goes to infinity in probability under K = .
Proof (of Corollary 2) : The proof extends the arguments of Wellek (2010), Section 3.1, from confidence intervals to confidence bands. Write H = H 1 ∪ H 2 where Suppose H is true and let without loss of generality be H 1 true due to analogy. Then the probability of a false rejection of H amounts to P(A 0 (s) − (s) < a n (s) and b n (s) ≤ P(A(s) < a n (s) for some s ∈ [t 1 , t 2 ]) −→ α.
Here the last inequality holds since H 1 is true and the convergence is due to the asymptotic coverage probability of the confidence band (a n (s), ∞) s∈[t 1 ,t 2 ] . In order to prove consistency, suppose the alternative hypothesis K is true and choose any ε such that Thus, by the (uniform) consistency of the Nelson-Aalen estimator and the wild bootstrap quantiles, the probability of a correct rejection of H equals P(A 0 (s) − (s) < a n (s) and b n (s) < A 0 (s) + u(s) for all s ∈ [t 1 , t 2 ]) ≥ P(A(s) − ε < a n (s) and b n (s) < A(s) + ε for all s ∈ [t 1 , t 2 ]) −→ 1 as n → ∞. For the convergence in the previous display, also note that a n P − − → A as

Proof (of Theorem 4)
: , τ ] the cone of positive càdlàg functions that are bounded away from zero. It is easy to see that the functional φ : g is Hadamard-differentiable tangentially to the set of pairs of continuous functions C 2 [t 0 , τ ] with continuous and linear Hadamard-derivative A simpler Hadamard-differentiability result holds for φ's restriction to τ , i.e., φ| τ : Hence, we apply the functional δ-method and the continuous mapping theorem to respectively, verifying their equality in distribution in the limit (conditionally in probability for the latter). Proceed similarly with the restricted functional φ| τ . Furthermore, the difference functional of both above functionals ensures the Hadamarddifferentiability tangentially to the set of pairs of continuous functions. Our specific choices of the distance ρ are continuous functionals. Hence we are able to apply the continuous mapping theorem again. To conclude the proof of the asymptotic behaviour of ϕ prop n 1 ,n 2 under H 0,prop , note that the particular weight function solves the problem of dividing by zero at t 0 = 0.
For the asymptotic power assertion, let t 1 ∈ [0, τ ] at which H 0,prop is violated. Then converges in probability to a positive value, whence T n 1 ,n 2 p → ∞ follows. The conditional quantiles, however, still converge to a finite constant in probability by the above arguments.

B Theoretical justification for the non-applicability of the ordinary multiplier resampling
In this part of the appendix, following the suggestion of a referee, we show in detail why the ordinary multiplier bootstrap fails to provide the correct limit process. For ease of presentation, we focus on the univariate Nelson-Aalen estimator in the special Markovian and uncensored multistate model: Let (X (t)) t denote a Markov process with state space {1, 2, . . . , k}, where k ≥ 2, i.e., given the present state of the process, the future development does not depend on previously occupied states. Without loss of generality, we focus on the transition from state 1 to state 2 in order to prove our claim. That is, we restrict attention to the cumulative hazard function given by A(dt) = A 12 (dt) = P(X (t + dt) = 2 | X (t) = 1); for ease of presentation, this subscript is omitted. Obviously, having shown that the competing resampling technique fails in this particular situation, the same is immediately implied in the general and multivariate case.
In this set-up, the alternative resampling approach is available because the counting process N for all 1 → 2 transitions is a sum of n ∈ N i.i.d. counting processes N i , i = 1, . . . , n, i.e., N = n i=1 N i . Hence, each counting process satisfies the Doob-Meyer decomposition (2.1) such that we have the martingale representation

Y (s)d A(s).
The ordinary multiplier bootstrap works as follows: Consider the martingale representation of the Nelson-Aalen estimator, where o p (1) p → 0 as n → ∞; cf. (2.3) and omit the index j therein. In the resampling step, the individual counting process martingales M i (u) are replaced with G i · N i (u). Here, G 1 , . . . , G n are i.i.d. random variables with zero mean and unit variance, which are independent of the data. The resulting ordinary multiplier bootstrap process shall be denoted as We now show that this approach asymptotically does not yield the appropriate correlation structure. The limit processes of the Nelson-Aalen estimator and its wild bootstrap version as discussed in Section 3.2 are centered Gaussian martingales and, thus, have independent increments. On the other hand, this does not hold for the limit process of W n : For any choice of 0 ≤ s ≤ t ≤ τ we have cov( W n (t), W n (s) | C 0 ) where the last convergence in probability holds due to the law of large numbers as n → ∞. Let X denote the Markov process underlying the counting process N 1 . A twofold application of Fubini's theorem yields that the above expectation equals (0,t] (0,s] 1 y(u) 1 y(v) E (dN 1 (u)dN 1 (v)).
As we assumed that there is no censoring, we have E dN 1 (u)dN 1 (v) = P(X (u) = 1, X (u + du) = 2, X (v) = 1, X (v + dv) = 2). Now, we distinguish between two different cases: First, we treat the diagonal which contributes the following integral to the asymptotic covariance: (0,min(s,t)] where Y 1 is the at risk indicator of the process X for a transition out of state 1. This integral corresponds to the asymptotic covariance function of the Nelson-Aalen estimator, cf. Theorem 1. Unfortunately, the overall asymptotic covariance of the alternative multiplier approach is increased due to the off-diagonal integral parts: In the case of u < v and due to the assumed Markov property, the above expected values reduce to E(dN 1 (u)dN 1 (v)) = P(X (u) = 1, X (u + du) = 2, X (v) = 1, X (v + dv) = 2) = P(X (v + dv) = 2 | X (v) = 1) P(X (v) = 1 | X (u + du) = 2) × P(X (u + du) = 2 | X (u) = 1) P(X (u) = 1) where P 21 (u, v) = P(X (v) = 1 | X (u) = 2). All in all, using y(u) = P(X (u) = 1), we obtain the following asymptotic covariance of the ordinary multiplier bootstrap version of the Nelson-Aalen estimator:  min(u, v), max(u, v)) y(max (u, v

)) d A(u)d A(v).
We may conclude two things from this covariance representation: First, we see that ψ(s, t) = ψ(s, t). That is, the asymptotic covariance function of the Nelson-Aalen estimator as given in Theorem 1 is altered by the ordinary multiplier bootstrap. As ψ(s, t) is in general not a function of min(s, t), the underlying limit Gaussian process does not even have independent increments. Hence, the alternative multiplier approach fails in reproducing an adequately distributed stochastic process. Second, we see that the correct limit covariance structure is ensured only if the second integral in the above representation of ψ vanishes. This is the case if P 21 ≡ 0 which holds, for example, if there is at most one 1 → 2 transition possible as in the competing risks special case. This is no surprise, though: In the competing risks set-up, both resampling options, our proposed wild bootstrap and the ordinary multiplier bootstrap, reduce to the same procedure; see Beyersmann et al. (2013) for the applicability of the wild bootstrap to Aalen-Johansen estimators in competing risks models.