\subsection{Scenario B}
In the first simulation study, data were simulated under the assumptions of Scenario {\bf B} (A1--A4, Case CB). 
Each simulated data set contained $n$ independent individuals, with potential outcomes and observed random variables generated as follows.  First, $(Y^{\tau}(1),Y^{\tau}(0))$ was set to  (0,0) or (1,1) with probabilities 0.8 and 0.2, respectively. Thus A4 (EECR) holds. 
If $ Y^{\tau}(1) =1$, then $Y(0)$ and $Y(1)$ were set to 1. 
If $ Y^{\tau}(1) =0$, then $(S^{*}(1),S^{*}(0))$ was set to (0,0) or (1,0) with probabilities 0.4 and 0.6, respectively, such that Case CB holds.

To evaluate size and power of a test of $H_{0}: CEP(1,0) = CEP(0,0)$ versus $H_{1} : CEP(1,0) \neq CEP(0,0)$, data were simulated under 13 different assumed values for \newline $CEP(1,0) - CEP(0,0)$, namely $-0.6, -0.5, \ldots, 0.6$.
Specifically, 
if $Y^{\tau}(1)=0$ and $S^{*}(1) = S^{*}(0) = 0$, 
	then $Y(1)$ was generated as Bernoulli with mean $a$
	and $Y(0)$ as Bernoulli with mean 0.5.
On the other hand, 
if $Y^{\tau}(1)=0$ and $S^{*}(1) = 1, S^{*}(0) = 0$, 
	then $Y(1)$ was Bernoulli with mean $b$
	and $Y(0)$ was Bernoulli with mean 0.5.
Thus $CEP(1,0) - CEP(0,0) = b-a$ for contrast function $h(x,y)=x-y$.
The values of $a$ ranged from 0.7 to 0.1 by decrements of 0.05 and $b$ increased from 0.1 to 0.7 by increments of 0.05.  
   Under this parameterization $risk_0(0,0)=0.5=risk_0(1,0)$, implying $\beta_0$ = 0.

To generate the observed data, 
 $Z$ was drawn from a Bernoulli distribution with $P(Z = 1) = 0.5$, and the vector of observable random variables 
$(Z,Y^{\tau},S^*,Y)=(Z,Y^{\tau}(Z),S^*(Z),$ \newline $Y(Z))$ was determined. Simulations were conducted with and without case-cohort sampling of $S^*$.
For the latter,
membership in the random subcohort was determined by $R$, a Bernoulli random variable with mean $\nu$. 
For individuals with $Y^{\tau}=0$,
$S^*$ was observed for subcohort members (i.e., $R=1$)
and cases (i.e., $Y=1$).
Thus the observed random vector equaled
$(Z,Y^{\tau},Y,R,S^*I(Y^{\tau}=0, \max\{R,Y\}=1))$. 

Data sets were generated for all 351 combinations of: 
$n \in \{400,800,1600\}; \nu \in \{0.1,$ \newline $ 0.25, 1\}$;
and 
$CEP(1,0) - CEP(0,0) \in \{-0.6,-0.5,\ldots,0.6\}$.
For each of these combinations, 2000 data sets of size $n$ were generated.  
Analyses used $[l_{0}, u_{0}] \in \{[0,0],[-1,1],[-2.5,2.5]\}$.
For each simulated data set, $CEP(1,0) - CEP(0,0)$ was estimated under the  Scenario {\bf B} assumption set. 
The null hypothesis $H_0$ was rejected if and only if the 95\% EUI for $CEP(1,0)-CEP(0,0)$ excluded 0. 
Power was estimated by the proportion of simulated data sets where $H_0$ was rejected (Figure 1).  Empirical type I error was always less than or  approximately equal to the nominal significance level $\alpha=0.05$.
As expected, power increased with sample size and decreased as the interval $[l_0, u_0]$ became wider and as the size of the subcohort decreased.
Figure 2 shows the average widths of the 95\% EUIs for $CEP(1,0)-CEP(0,0)$.
The EUIs cover at approximately the nominal rate when $l_0=u_0$, i.e., when  $CEP(1,0)-CEP(0,0)$ is identifiable, and are conservative otherwise.
The widths are relatively constant across values of $CEP(1,0)-CEP(0,0)$ and increase as the size of the random subcohort decreases.
Empirical coverage of the 95\% EUIs are plotted in Web Figure 1 (Web Appendix C).
Web Figures 2 and 3 display bias 
of the $CEP(1,0)-CEP(0,0)$ estimates and ratios of the empirical standard errors (ESE) to the average of the sandwich variance estimated standard errors (ASE), showing unbiasedness of both the point and standard error estimators.

\begin{figure}
\centering
\includegraphics[scale=0.9]{Fig1results2000sims.pdf}
\caption{Power to reject $H_{0}: CEP(1,0) = CEP(0,0)$ for the simulation study under Scenario {\bf B}.
Solid black lines denote full cohort and dashed (dotted) lines denote case-cohort with 10\% (25\%) random subcohort.
Horizontal gray lines denote significance level $0.05$.
}
\end{figure}

\begin{figure}
\centering
\includegraphics[scale=0.9]{Fig2results2000sims-eui.pdf}
\caption{Average 95\% EUI width for the simulation study under Scenario {\bf B}.
Solid lines denote full cohort and dashed (dotted) lines denote case-cohort with 10\% (25\%) random subcohort.
}
\end{figure}

The data sets simulated under Scenario {\bf B} were not analyzed with Scenario {\bf A} methods that allow $S^*(0)$ to vary, because, 
as described in the Introduction, in Scenario {\bf B} Case CB is known to be true structurally by the 
definition of $S^*(0)$.
In addition, it is not advisable to use Scenario {\bf C} methods because validity requires 
A4$^{\prime \prime}$: $P(Y^{\tau}(1)=1) < P(Y^{\tau}(0)=1)$ as discussed in Section 4.2, which can be diagnosed
to be dubious for many data sets because they are generated from a distribution 
with $P(Y^{\tau}(1)=1) = P(Y^{\tau}(0)=1)$. 


In the second simulation study, data were simulated under the assumptions of scenario {\bf C} (A1-A3, A4', Case CB) such that A4 in scenario {\bf B} failed. 
First $(Y^{\tau}(1),Y^{\tau}(0))$ was set to (0,0), (0,1), or (1,1) with probabilities 0.7, 0.2, and 0.1, such that A4' (ENHM) holds.
If $Y^{\tau}(z) = 1$, then $Y(z)$ was set to 1.
Similar to the first simulation, if $(Y^{\tau}(1),Y^{\tau}(0)) = (0,0)$, then $(S^{*}(1),S^{*}(0))$ was set to (0,0) or (1,0) with probabilities 0.4 and 0.6. If $(Y^{\tau}(1),Y^{\tau}(0)) = (0,1)$, then $S^{*}(1)$ was set to 0 or 1 with probabilities 0.4 and 0.6. 
 
To evaluate the power of the test of the same hypotheses as the first simulation, data were simulated under the same thirteen values of $CEP(1,0) - CEP(0,0)$ as before. 
Randomization assignment $Z$ and the observed data were also generated as in the first simulation,
for all 351 combinations of: $n \in \{2000,4000,8000\}; \nu \in \{0.1,0.25,1\};$ and $CEP(1,0) - $ \newline $CEP(0,0) \in \{-0.6, -0.5,\ldots ,0.6\}$. 
Analyses used $[l_{j},u_{j}] \in \left\{ [0,0],[-0.5,0.5],[-1,1] \right\}$ for $j=0,2,3,4$. 
As for the Scenario {\bf B} simulations, all data sets were simulated under no selection bias.  Results based on 2000 simulated data sets are shown in Figures 3 -- 4 and Web Figure 4 -- 6. As for scenario {\bf B}, power and precision diminished as the interval $[l_0, u_0]$ became wider and the subcohort size decreased.

\begin{figure}
\centering
\includegraphics[scale=0.9]{Fig3results2000simsC.pdf}
\caption{Power to reject $H_{0}: CEP(1,0) = CEP(0,0)$ for the simulation study under Scenario {\bf C}.
Solid black lines denote full cohort and dashed (dotted) lines denote case-cohort with 10\% (25\%) random subcohort.
Horizontal gray lines denote significance level $0.05$.
}
\end{figure}

\newpage
\begin{figure}
\centering
\includegraphics[scale=0.9]{Fig4results2000simsC-eui.pdf}
\caption{Average 95\% EUI width for the simulation study under Scenario {\bf C}.
Solid lines denote full cohort and dashed (dotted) lines denote case-cohort with 10\% (25\%) random subcohort.
}
\end{figure}

\vspace{.14in}

\noindent {\bf 6. Application: HVTN 505 HIV Vaccine Efficacy Trial}

We apply the methods to HVTN 505 for three different binary markers defined based on the PFS or antibody measurements at Month 6.5 described in the Introduction.  These binary markers $S$ are the indicators of whether (S1) the PFS exceeds the median, (S2) the antibodies exceed the median, or (S3) either PFS or antibodies exceed the median. 
For marker S1, 70 of 125 (56\%) uninfected vaccinees have $S^*=1$, compared to 5 of 25 (20\%) infected vaccinees.  For S2 these rates are 66 of 125 (53\%) and 9 of 25 (36\%), respectively,
whereas for S3 these rates are 91 of 125 (73\%) and 10 of 25 (40\%).

Case CB holds in HVTN 505, as it generally does in preventive HIV vaccine efficacy trials, because biomarker values (which are measures of HIV-specific responses to vaccination) are zero for those assigned placebo.  
Given Case CB holds, we conduct the analysis under assumption scenarios {\bf B} and {\bf C}, 
and thus our goal is inference on $CEP(0,0)$ and $CEP(1,0)$. We use a vaccine efficacy contrast $h(x,y)=1-x\slash y$ such that the analysis assesses
$VE(0) \equiv CEP(0,0)$ and $VE(1) \equiv CEP(1,0)$, respectively.
The scenario {\bf B} method requires A5, which trivially holds, and A4 (EECR), which is defensible given that 
$\widehat P(Y^{\tau}(1)=1) = 14/1251 = 0.011$ and $\widehat P(Y^{\tau}(0)=1) = 10/1245 = 0.0080$ with Fisher's exact test 2-sided p-value 
of $p=0.54$ for a difference. In contrast, the scenario {\bf C} method requires A4$^{\prime}$, which relaxes A4 but at the cost of adding more sensitivity parameters. 
In addition, for Wald CIs and EUIs to have nominal coverage under scenario {\bf C},
A4$^{\prime \prime}$ ($P(Y^{\tau}(1)=1) < P(Y^{\tau}(0)=1)$) must hold as described in Section 4.2, which does not seem
to be true in this example.  Thus scenario {\bf B} may be the most reasonable, and we focus on it, but we also apply the method under scenario {\bf C} for illustration purposes.
The methods are implemented exactly as in the simulation study.  Web Appendix D studies why {\bf B} and {\bf C} are essentially equivalent for HVTN 505, where extra simulations suggest that a key part of the explanation is that
$P(Y^{\tau}(1)=1,Y^{\tau}(0)=0)$ is small. 




Figure 5 shows the results in terms of ignorance intervals and 95\% EUIs under each of the three ranges of sensitivity parameters specified in the simulations, the top panel for $VE(1) - VE(0)$ and the bottom panel for $VE(0)$ and $VE(1)$. 
First, note that the scenario {\bf B} and {\bf C} methods give very similar results (top panel), with EUIs for the latter method only very slightly wider (and thus the bottom panel only shows results from the scenario {\bf B} method).   Second, 
for the antibody marker S2, there is no evidence for $VE$ modification, with 95\% EUIs about $VE(1) - VE(0)$ always including 0.
Third, the results are similar for markers S1 and S3, where if there is assumed
to be no selection bias (left panel), then there is clear evidence for $VE$ modification (with 95\% EUIs for $VE(1) - VE(0)$ comfortably excluding 0), whereas accounting for selection bias makes this result borderline significant with the EUIs just bordering 0 and depending on the amount of selection bias assumed (middle and right panels). For the PFS marker S2, $VE(1)$ is estimated to be 0.784, 0.723--0.821, and 0.624--0.844 under the models allowing no, intermediate, and highest degrees of selection bias, with 95\% EUIs 0.572--0.996, 0.483--0.975, and 0.304--0.973, respectively.  In addition, the point estimates of $VE(0)$ are consistently negative, suggesting a qualitative interaction may have occurred, although the 95\% EUIs always include 0 (for all three markers), suggesting no clear evidence of negative vaccine efficacy for vaccine recipients with low immune response.  Overall the results suggest that the vaccine may have conferred some protection for vaccine recipients with PFS responses exceeding the median, where another efficacy trial would be needed to verify this result.  The HIV vaccine field has ``moved on" from the DNA/rAd5 type of HIV vaccine platform, no longer considering it.  Thus these new results are significant for sounding a note of caution to completely giving up on this approach, in suggesting that if a new version of the regimen could be invented that induces high PFS responses in a vastly larger subgroup of vaccine recipients, then it could potentially confer high enough overall vaccine efficacy to confer worthwhile public health benefit. 

\begin{figure}
\centering
\includegraphics[scale=0.9]{plot505AbCD8VEscale.pdf}
\caption{For HVTN 505, ignorance intervals (solid lines) and 95\% EUIs (dashed lines) for $VE(0)=CEP(0,0)$ and $VE(1)=CEP(1,0)$ and $VE(1)-VE(0)$ with binary Month 6.5 marker $S^*$ defined by the indicator of whether (S1) the PFS exceeds the median, (S2) the antibodies exceed the median, or (S3) either PFS or antibodies exceed the median. 
The sensitivity analysis allows $\beta_0$ and $\beta_1$ to vary over $[l_0,u_0]=[0,0], [-0.5,0.5]$, or $[-1,1]$; circles are point estimates assuming no selection bias.  The top panel shows results for $VE(1)-VE(0)$ with the black and grey lines (left and right) results for the scenario {\bf B} and {\bf C} method, respectively. The bottom panel shows scenario {\bf B} results for $VE(1)$ and $VE(0)$.} 
\end{figure}

\vspace{.14in}

\noindent {\bf 7. Discussion}

A sizable literature on statistical methods for inference on the survival average causal effect (SACE) has developed over the past 20 years.  Motivated by a need for the HVTN 505 study, we described how these methods can be adapted to the problem of principal stratification effect modification (PSEM) evaluation in a randomized clinical trial with a binary intermediate response variable.  This provides new tools for PSEM analysis, expanding applicability to more settings, including: 
(1) to allow inference under a no negative early treatment effects assumption rather than the much stronger no early treatment effects assumption; (2) to allow inferences for studies with no adequate baseline predictors of the intermediate endpoint available and for which closeout placebo vaccination was not performed; and (3) to accommodate the sub-sampling design of the intermediate endpoint. These extensions were all 
needed for HVTN 505, with (1) relaxing a dubious assumption and (2) and (3) fitting the study design realities.  Moreover, the new methods avoid making a strong structural placebo conditional risk assumption made by most available PSEM methods, which was a necessary innovation for assessing a qualitative interaction in HVTN 505 given the appropriate skepticism that the DNA/rAd5 vaccine could have both beneficial and detrimental effects despite having no efficacy overall.
The data analysis provides the first direct evidence that vaccinated subgroups with high CD8+ T cell polyfunctionality score (PFS) responses to DNA/rAd5 vaccination had beneficial vaccine efficacy to prevent HIV-1 infection, which supports further research seeking to re-engineer the vaccine regimen to generate high PFS responses in more vaccine recipients.  


The new PSEM methods were developed under three common assumption scenarios that occur in randomized trials.  
An important decision for the analysis of a given data set is whether 
to use the scenario {\bf B} or {\bf C} method, with difference that the latter relaxes the
no early treatment effects assumption to monotonicity. For data sets with a small estimated value of $P(Y^{\tau}(1) = 1, Y^{\tau}(0) = 0)$, our simulations and application show that the 
methods tend to give similar results, with the intervals from scenario {\bf C} being only slightly wider than those from Scenario {\bf B}. Because there are many applications where monotonicity is much more plausible that no early treatment effects, in general the scenario {\bf C} method may be preferred unless there is compelling knowledge that no early treatment effects holds.



\vspace{.12in}
\noindent {\bf Supplementary Materials}
\begin{description}
\item[Title: Supportive results] The supportive results include (A) Application of Chiba and VanderWeele's (2011) SACE method for evaluating a binary principal stratification effect modifier under Scenarios {\bf A} and {\bf B};
(B) Adapting the SACE methods for a time-to-event outcome with right-censoring;
(C) Web Figures 1--6 simulation study results; 
(D) Additional Application results; and (E) Complete computer code.
\end{description}

\vspace{.12in}
\noindent {\bf Acknowledgements}

We thank the participants and investigators of HVTN 505, in particular Youyi Fong, Holly Janes, Georgia Tomaras, and Julie McElrath for providing the marker data for the example. Research reported in this publication was supported by the National Institute Of Allergy And Infectious
Diseases of the National Institutes of Health under Award Number R37AI054165 and 
the U.S. Public Health Service Grant AI068635.
The content is
solely the responsibility of the authors and does not necessarily represent the official views of
the National Institutes of Health.


\section{Web Appendix A: Application of Chiba and VanderWeele's (2011) SACE Method for Evaluating a Binary Principal Surrogate Under Scenarios {\bf A} and {\bf B}}

We show how the simple SACE method of Chiba and VanderWeele (2011) can be applied to evaluate a binary principal surrogate using an additive contrast $h(x,y)=x-y$.
Define two sensitivity parameters $\alpha_k$, $k=0,1$, by
$\alpha_k \equiv P(Y(k)=1|Z=1,S_k=1) - P(Y(k)=1|Z=0,S_k=1)$ with
$S_0 \equiv [1-Y^{\tau}][1-S^*]$ and $S_1 \equiv [1-Y^{\tau}]S^*$.  Then
\begin{eqnarray}  
CEP(k,k;\alpha_k) & = & P(Y=1|Z=1,S_k=1) - P(Y=1|Z=0,S_k=1) - \alpha_k \label{eq: SACEkk} \\
          & = & \mu_{1k} - \mu_{0k} - \alpha_k \hspace{.2in} {\rm for} \hspace{.1in} k=0,1. \nonumber
\end{eqnarray}

\noindent A simple approach to estimating each 
$\mu_{zk}$, $(z,k) \in \lbrace (0,0), (0,1), (1,0), (1,1) \rbrace$, solves \newline
$\sum_{i=1}^n R_i U^{0zk}_i(O_i;\mu_{zk}) \slash \pi(O_i,\widehat \psi) = 0$ with
$U^{0zk}_i(O_i;\mu_{zk}) \equiv (1-Y^{\tau}_i)I(Z_i=z)I(S^*=k)(Y_i - \mu_{zk}) \slash n_{zk}$.
Then, $CEP(k,k;\alpha_k)$ is estimated by $\widehat \mu_{1k} - \widehat \mu_{0k} - \alpha_k$ where
$\alpha_k$ is a known constant fixed by the user. 
Lastly, plugging the above estimates into 
equation (2) [or equation (5)]
of the main article yields estimates of $risk_1(1,0;\alpha_1)$ and $risk_0(1,0;\alpha_0)$, and hence of $CEP(1,0;\alpha_0,\alpha_1)$. 

By standard estimating equation theory, the above estimators are consistent and asymptotically normal for given fixed $\alpha_0$ and $\alpha_1$. 
To obtain Wald confidence intervals for each $CEP(s_1,s_0;\alpha_0,\alpha_1)$, consistent sandwich variance estimators may be used,
e.g., the estimated variance of $\mu_{zk}$ for each $k=0,1$ is given by 
$\sum_{i=1}^n \left( R_i \slash \pi(O_i,\widehat \psi) \right) \left[  U^{0zk}_i(O_i;\widehat \mu_{zk}) 
\right]^2.$  The estimated variance of $\widehat{CEP}(1,0)$ may be obtained by the delta method.

To perform a sensitivity analysis, the user specifies a plausible range $[l_k, u_k]$ (or maximum possible) for each $\alpha_k$, $k=0,1$. An ignorance interval for $CEP(s_1,s_0)$ may be calculated 
as the minimum and maximum estimates (obtained with $\alpha_0$ and $\alpha_1$ set to the boundary values). Using the method of Imbens and Manski (2004)\nocite{ImbensManski2004} and
Vansteelandt et al. (2006)\nocite{Vansteelandtetal2006}, a Wald asymptotic (1-$\alpha$)\% estimated uncertainty interval (EUI) for $CEP(s_1,s_0)$ may be calculated 
as in formulas (40) and (41) of Richardson et al. (2014),\nocite{Richardsonetal2014}
using the variance estimates of the minimum and maximum $CEP(s_1,s_0)$ estimates. This approach requires that $CEP(k,k;\alpha_k)$ is monotone in $\alpha_k$, which holds by
(\ref{eq: SACEkk}).  The same approach can be used to construct Wald confidence intervals and EUIs for the other scenarios and SACE approaches described below.

\section{Web Appendix B: Adapting the SACE Methods for a Time-to-Event Outcome with Right-Censoring}

The approach to estimation of $CEP(0,0)$, $CEP(1,0)$, and $CEP(1,1)$ using the published SACE methods described above is similar if the binary outcome
$Y$ is defined as $Y \equiv I(T \le t)$ with $T$ subject to right-censoring and $t$ is a fixed time point of interest.
The estimating equations used to estimate the needed terms are 
the same as those described above, except that 
new estimating functions $U(O_i;\cdot)$ are swapped into the equations that are designed to handle
the right-censoring.  For example, consider the first estimating equation
in Section 3.2,
$\sum_{i=1}^n U^{0z}_i(O_i;risk_z)=0$.
With $Y \equiv I(T \le t)$, the same estimating equation can be used
swapping in the estimating function of the Kaplan-Meier estimator (Reid, 1981) or of the
targeted maximum likelihood estimator of a survival curve (Moore and van der Laan, 2009). The same type of swap is 
made for the other estimating equations.  As described in Shepherd et al. (2007, 2011), a modification to the weight functions $w_z(\cdot;\alpha_z,\beta_z)$ is needed,
where now they are indexed by time $t$:
$w_z(t;\alpha_z,\beta_z) = \lbrace 1 + {\rm exp}(-\alpha_z -\beta_z {\rm min}(t,\nu)) \rbrace^{-1}$, where $\nu$ is near the end of follow-up.
In addition, the summation $\sum_{y=0}^1 w_0(y;\alpha_0,\beta_0)\widehat P(Y(0)=y|S(0)=1)$ in equation (6) 
of the main article is changed to
$\int_0^{\infty} w_0(t;\alpha_0,\beta_0)\widehat P(T(0)\le t|S(0)=1)$ and 
the summation $\sum_{y=0}^1 w_1(y;\alpha_1,\beta_1)\widehat P(Y(1)=y|S(1)=1)$ in equation (7) 
of the main article is changed to
$\int_0^{\infty} w_1(t;\alpha_1,\beta_1)\widehat P(T(1)\le t|S(1)=1)$.



\newpage

\section{Web Appendix C: Additional Figures Showing Results of the Simulation Study}

\begin{center}
\begin{figure}
\includegraphics[scale=.85]{Suppfig1results2000sims-cover.pdf}
\end{figure}
\end{center}
Web Figure 1. 95\% EUI coverage for simulation study under scenario {\bf B}.
Solid line denotes full cohort, dashed (dotted) line denotes case-cohort with 10\% (25\%) random subcohort.

\newpage
\begin{center}
\begin{figure}
\includegraphics[scale=.85]{Suppfig2results2000sims-bias.pdf}
\end{figure}
\end{center}
Web Figure 2. Bias for simulation study under scenario {\bf B}.
The middle and lower panels show bias of the minimum and maximum estimates of $CEP(1,0)-CEP(0,0)$ over
the plausible region $\Gamma=[l_0,u_0]$ of the sensitivity parameter $\beta_0$. 
Solid line denotes full cohort, dashed (dotted) line denotes case-cohort with 10\% (25\%) random subcohort.


\newpage
\begin{center}
\begin{figure}
\includegraphics[scale=.85]{Suppfig3results2000sims-se.pdf}
\end{figure}
\end{center}
Web Figure 3.
Ratio of empirical standard error (ESE) to average estimated standard error (ASE) for simulation study under scenario {\bf B}.
Solid line denotes full cohort, dashed (dotted) line denotes case-cohort with 10\% (25\%) random subcohort.

\newpage
\begin{center}
\begin{figure}
\includegraphics[scale=.85]{Suppfig4results2000simsC-cover.pdf}
\end{figure}
\end{center}
Web Figure 4.
95\% EUI coverage for simulation study under scenario {\bf C}.
Solid line denotes full cohort, dashed (dotted) line denotes case-cohort with 10\% (25\%) random subcohort.


\newpage
\begin{center}
\begin{figure}
\includegraphics[scale=.85]{Suppfig5results2000simsC-bias.pdf}
\end{figure}
\end{center}
Web Figure 5. Bias for simulation study under scenario {\bf C}.
The middle and lower panels show bias of the minimum and maximum estimates of $CEP(1,0)-CEP(0,0)$ over
the plausible region $\Gamma=[l_0,u_0]$ of the sensitivity parameter $\beta_0$. 
Solid line denotes full cohort, dashed (dotted) line denotes case-cohort with 10\% (25\%) random subcohort.


\newpage
\begin{center}
\begin{figure}
\includegraphics[scale=.85]{Suppfig6results2000simsC-se.pdf}
\end{figure}
\end{center}
Web Figure 6. Ratio of empirical standard error (ESE) to average estimated standard error (ASE) for simulation study under scenario {\bf C}.
Solid line denotes full cohort, dashed (dotted) line denotes case-cohort with 10\% (25\%) random subcohort.

\newpage

\section{Web Appendix D: Additional Analyses for the Application}

\subsection{Explanation of How the Results of the Application are Very Similar for the Scenario {\bf B} and {\bf C} Methods}

In this web appendix we show that under the condition $P(Y(0)=1|Y^{\tau}(1)=1,Y^{\tau}(0)=0) =
P(Y(0)=1|Y^{\tau}(1)=0,Y^{\tau}(0)=0)$, then the scenario {\bf B} and scenario {\bf C}methods 
are equivalent.   
The typical estimand of interest in the article, $CEP(1,0)-CEP(0,0)$, is a function of $risk_{1}(1,0), risk_{1}(0,0), risk_{0}(1,0),$ and $risk_{0}(0,0)$. Under the setup for scenario {\bf C} in the application section, we switch the direction of the monotonicity assumption which, when combined with case CB, identifies $risk_{1}(1,0)$ and $risk_{1}(0,0)$. Thus, $risk_{1}(1,0)$ and $risk_{1}(0,0)$ are estimated in exactly the same way for the two scenarios:

\begin{align*}
\widehat{risk}_{1}(j,0) &= \widehat{P}(Y(1) = 1 | S^{*}(1) = j, S^{*}(0) = 0, Y^{\tau}(1) = 0, Y^{\tau}(0) = 0) \\
&= \widehat{P}(Y(1) = 1 | S^{*}(1) = j, Y^{\tau}(1) = 0) \\
&= \widehat{P}(Y = 1 | S^{*} = j, Y^{\tau} = 0, Z = 1), \quad j=0,1
\end{align*}

Therefore the results under each scenario will only differ in estimation of $risk_{0}(1,0)$ and $risk_{0}(0,0)$.

\noindent {\it Scenario B.}  Under scenario {\bf B}, $risk_{0}(1,0)$ and $risk_{0}(0,0)$ are estimated with a SACE method equivalent to solving the following mixing equations:

\begin{equation*}
exp(\beta_{0}) = \frac{risk_{0}(0,0) / (1-risk_{0}(0,0))}{risk_{0}(1,0) / (1-risk_{0}(1,0))}
\end{equation*}

\noindent and
\begin{equation*}
risk_{0} = p(0,0)risk_{0}(0,0) + (1-p(0,0))risk_{0}(1,0),
\end{equation*}

\noindent where $risk_{0}$ and $p(0,0)$ are identifiable under the assumptions of scenario {\bf B}. By EECR, we estimate:

\begin{align*}
\widehat{risk_{0}} &= \widehat{P}(Y(0) = 1 | Y^{\tau}(1) = 0, Y^{\tau}(0) = 0) \\
&= \widehat{P}(Y(0) = 1 | Y^{\tau}(0) = 0) = \widehat{P}(Y = 1 | Y^{\tau} = 0, Z = 0),
\end{align*}

\noindent which is solved by the estimating equation

\begin{equation*}
\sum_{i}(1-Z_{i})(1-Y^{\tau}_{i})(Y-risk_{0}) = 0.
\end{equation*}

In addition, by EECR and Case CB,

\begin{align*}
\widehat{p}(0,0) &= \widehat{P}(S^{*}(1) = 0, S^{*}(0) = 0 | Y^{\tau}(1) = 0, Y^{\tau}(0) = 0) \\
&= \widehat{P}(S^{*}(1) = 0 | Y^{\tau}(1) = 0) = \widehat{P}(S^{*} = 0 | Y^{\tau} = 0, Z = 1),
\end{align*}

which is solved by the estimating equation

\begin{equation*}
\sum_{i}Z_{i}(1-Y^{\tau}_{i})(1-S^{*}-p(0,0)) = 0.
\end{equation*}

\noindent Then $risk_{0}(1,0),$ and $risk_{0}(0,0)$ are estimated by solving the mixing equations once $\beta_{0}$ is specified.

\noindent {\it Scenario C.}
Under scenario {\bf C}, we relax the EECR assumption $[P(Y^{\tau}(1) = Y^{\tau}(0)) = 1]$ to 
ENHM $[P(Y^{\tau}(1) \geq Y^{\tau}(0)) = 1]$. Now, $risk_{0} = P(Y(0) = 1 | Y^{\tau}(1) = Y^{\tau}(0) = 0)$ is no longer identifiable. So first, an intermediate SACE method must be performed to estimate $risk_{0}$, and then the same SACE method as above is performed to estimate $risk_{0}(1,0)$ and $risk_{0}(0,0)$. We can write mixing equations in a similar form to those in the previous section (with some slight abuse of notation in defining $\beta_{1}$ as compared to the main text):

\begin{equation*}
exp(\beta_{1}) = \frac{risk_{0} / (1-risk_{0})}{P(Y(0) = 1 | Y^{\tau}(1) = 1, Y^{\tau}(0) = 0) / (1-P(Y(0) = 1 | Y^{\tau}(1) = 1, Y^{\tau}(0) = 0))}
\end{equation*}

\noindent and 
\begin{align*}
P(Y(0) = 1 | Y^{\tau}(0) = 0) &= P(Y^{\tau}(1) = 0 | Y^{\tau}(0) = 0)risk_{0} \\
&+ P(Y^{\tau}(1) = 1 | Y^{\tau}(0) = 0)P(Y(0) = 1 | Y^{\tau}(1) = 1, Y^{\tau}(0) = 0)
\end{align*}

\noindent where $P(Y^{\tau}(1) = 1 | Y^{\tau}(0) = 0) = 1 - P(Y^{\tau}(1) = 0 | Y^{\tau}(0) = 0)$.
Note that $\beta_{1}=0$ expresses the equality $P(Y(0)=1|Y^{\tau}(1)=1,Y^{\tau}(0)=0) =
P(Y(0)=1|Y^{\tau}(1)=0,Y^{\tau}(0)=0)$.  Now, when $\beta_{1} = 0$, we estimate

\begin{align*}
\widehat{risk}_{0} &= \widehat{P}(Y(0) = 1 | Y^{\tau}(1) = 1, Y^{\tau}(0) = 0) \\
&= \widehat{P}(Y(0) = 1 | Y^{\tau}(0) = 0) = \widehat{P}(Y = 1 | Y^{\tau} = 0, Z = 0),
\end{align*}

\noindent which is found by solving the same estimating equation as in scenario {\bf B}:

\begin{equation*}
\sum_{i}(1-Z_{i})(1-Y^{\tau}_{i})(Y-risk_{0}) = 0.
\end{equation*}

\noindent Therefore the estimate for $risk_{0}$ in scenario {\bf C} will be the same as that in scenario {\bf B} when $\beta_{1} = 0$. In addition, the estimate for $p(0,0)$ under scenario {\bf C}will be the same as that under scenario {\bf B} by monotonicity and Case CB:

\begin{align*}
\widehat{p}(0,0) &= \widehat{P}(S^{*}(1) = 0, S^{*}(0) = 0 | Y^{\tau}(1) = 0, Y^{\tau}(0) = 0) \\
&= \widehat{P}(S^{*}(1) = 0 | Y^{\tau}(1) = 0) = \widehat{P}(S^{*} = 0 | Y^{\tau} = 0, Z = 1),
\end{align*}

\noindent which is solved by the same estimating equation:

\begin{equation*}
\sum_{i}Z_{i}(1-Y^{\tau}_{i})(1-S^{*}-p(0,0)) = 0.
\end{equation*}

\noindent After estimating these terms, $risk_{0}(1,0)$ and $risk_{0}(0,0)$ are estimated via the same SACE method described for scenario {\bf B}. We have shown that when $\beta_{1} = 0$, the estimated $risk_{0}$ and $p(0,0)$ used in the mixing equations will be the same as those estimated in B. Thus, the estimated $risk_{0}(1,0)$ and $risk_{0}(0,0)$ (as well as the estimate of $CEP(1,0)-CEP(0,0)$) will be the same under both scenarios when $\beta_{1} = 0$.

As $\beta_{1}$ moves further away from 0, the estimates for $risk_{0}$ will become more different between the two methods, as will the subsequent results. Note that this is different from what was described in the methods and simulation sections, where the method for scenario {\bf C} is more complex due to the monotonicity assumption being in the usual direction.

\subsection{Repeating the Application with a new contrast function and a omparison of results in the Application for scenarios {\bf B} or {\bf C} under different early infection data distributions}

Web Figure 7 shows the identical results as Figure 5, except using a log relative risk contrast function $h(x,y) = $log$(x\slash y)$ and transforming the ignorance interval and EUI limits back to the $VE$ scale $h(x,y) = 1 - x\slash y$.

\begin{center}
\begin{figure}
\includegraphics[scale=0.9]{plot505AbCD8logRRtransformedbacktoVEscale.pdf}
\end{figure}
\end{center}
Web Figure 7.  For HVTN 505, ignorance intervals (solid lines) and 95\% EUIs (dashed lines) for $VE(0)=1-{\rm exp}(CEP(0,0))$ and $VE(1)=1-{\rm exp}(CEP(1,0))$ and $RR(1)/RR(0) = (1-VE(1))/(1-VE(0))$ with binary Month 6.5 marker $S^*$ defined by the indicator of whether (S1) the PFS exceeds the median, (S2) the antibodies exceed the median, or (S3) either PFS or antibodies exceed the median. 
The sensitivity analysis allows $\beta_0$ and $\beta_1$ to vary over $[l_0,u_0]=[0,0], [-0.5,0.5]$, or $[-1,1]$; circles are point estimates assuming no selection bias.  The top panel shows results for $RR(1)/RR(0)$ with the black and grey lines (left and right) results for the scenario {\bf B} and {\bf C} method, respectively. The bottom panel shows scenario {\bf B} results for $VE(1)$ and $VE(0)$.

As described in the application section of the main text, there may be situations where it is not clear whether the assumptions of scenario {\bf B} or C hold for the data being used. We study this issue by simulating the difference in EUI widths for the two scenarios under various supposed values of $P(Y^{\tau}(1) = 1, Y^{\tau}(0) = 0)$, which is implicitly assumed to be 0 under Scenario {\bf B}, but not under scenario {\bf C}. Each point on the plot in Web Figure 8 is the average of the differences in EUI widths calculated across 100 simulations. The red line represents the estimated value of $P(Y^{\tau}(1) = 1, Y^{\tau}(0) = 0)$ for the HVTN 505 data set analyzed in the application section.

\begin{center}
\begin{figure}
\includegraphics[scale=.5]{SACESuppFigureEarlyInfection.pdf}
\end{figure}
\end{center}
Web Figure 8. Difference in 95\% EUI width for the HVTN 505 application in the main article for analysis under scenario {\bf B} versus under scenario {\bf C}. 

For data sets with a small estimated value of $P(Y^{\tau}(1) = 1, Y^{\tau}(0) = 0)$, we would expect the two methods to give very similar results, with the intervals from scenario {\bf C} being only slightly wider than those from scenario {\bf B}. For such data sets it may be unclear whether to analyze under scenario {\bf B} or scenario {\bf C}. In general, justification for use of the scenario {\bf B} method would need to come from knowledge that the EECR assumption is plausibly true.  

