{'fraction_non_alphanumeric': 0.04711714424702912, 'fraction_numerical': 0.01334290810535338, 'mean_word_length': 4.32962962962963, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 1, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 5, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Causal Inference under Outcome-Based Sampling with Monotonicity Assumptions

We study causal inference under case-control and case-population sampling. For this purpose, we focus on the binary-outcome and binary-treatment case, where the parameters of interest are causal relative and attributable risk defined via the potential outcome framework. It is shown that strong ignorability is not always as powerful as it is under random sampling and that certain monotonicity assumptions yield comparable results in terms of sharp identified intervals. Specifically, the usual odds ratio is shown to be a sharp identified upper bound on causal relative risk under the monotone treatment response and monotone treatment selection assumptions. We then discuss averaging the conditional (log) odds ratio and propose an algorithm for semiparametrically efficient estimation when averaging is based only on the (conditional) distributions of the covariates that are identified in the data. We also offer algorithms for causal inference if the true population distribution of the covariates is desirable for aggregation. We show the usefulness of our approach by studying two empirical examples from social sciences: the benefit of attending private school for entering a prestigious university in Pakistan and the causal relationship between staying in school and getting involved with drug-trafficking gangs in Brazil.


Introduction
Random sampling from the population of interest provides a convenient setup for causal inference, but it may be overly expensive to implement in practice for various reasons. For instance, some events are so rare that they are unlikely to be observed at random and therefore they are likely to be severely under-represented in a random sample. Examples include cancer (Breslow & Day 1980), infant death (Currie & Neidell 2005), consumer bankruptcy (Domowitz & Sartain 1999), entering a highly prestigious university (Delavande & Zafar 2019), and drug trafficking (Carvalho & Soares 2016), among many others. The main focus of this paper is to study causal inference when only an outcome-based sample is available. Specifically, data are collected by observing individuals that are randomly drawn from those to whom the event of interest is already known to have occurred, while the comparison group data are obtained similarly by focusing on those to whom the event did not occur (hence, case-control design; see, e.g., Breslow (1996)), or simply from an auxiliary source on the entire population without knowing their case status (as a consequence, case-population design; see, e.g., Lancaster & Imbens (1996)).
Both sampling designs can be analyzed in a unified outcome-based sampling framework called Bernoulli sampling (see, e.g., Breslow et al. (2000)). Therefore, our objective is to conduct causal inference under Bernoulli sampling.
We focus on the binary-outcome and binary-treatment case while data are only observational, as opposed to experimental. In a lesser-known paper, Holland & Rubin (1988) adopt the potential outcome framework to illustrate how to use the assumption of strong ignorability-which implies conditional independence between potential outcomes and treatment given covariates-to identify the counterfactual odds ratio in case-control studies. They then argue that the counterfactual odds ratio approximates the ratio of two potential-outcome probabilities (i.e., causal relative risk) under the rare-disease assumption. Their work is the starting point of this paper. We share their motivation that "retrospective studies are never randomized." However, strong ignorability is often considered too demanding for observational data; furthermore, in case-control studies, without having the knowledge of the true probability of the case in the population, strong ignorability without the rare-disease assumption is generally not sufficient to point identify the causal relative risk given the covariates. In this paper, we develop new identification results from the perspective of partial identification (see, e.g., Manski 1995, 2003, Tamer 2010, Molinari 2020, among others), without resorting to strong ignorability, nor to the rare-disease assumption.
In particular, we adopt the assumptions of monotone treatment response (Manski 1997, MTR hereafter) and monotone treatment selection (Manski & Pepper 2000, MTS hereafter) and show that those assumptions enable us to bound causal parameters in a meaningful way. The MTR and MTS assumptions as well as other related notions of monotonicity have been extensively used for causal inference.
We investigate partial identification of adjusted causal relative and attributable risk, that is, the ratio of two counterfactual proportions (conditional on covariates) and the difference between them. We show that strong ignorability is not always as powerful as it is under random sampling and that the MTR and MTS assumptions yield comparable results in terms of sharp identified intervals. Specifically, the odds ratio is shown to be a sharp upper bound on causal relative risk. Therefore, the odds ratio plays a central role for causal inference under the MTR and MTS assumptions that, unlike strong ignorability, allow for endogenous treatment assignment. We apply the same approach to causal attributable risk, although the sharp bounds are more complicated than the odds ratio.
In addition to new identification results, we develop easy-to-implement infer-ence algorithms for causal relative and attributable risk. Instead of parametrizing the functional causal parameters, we propose to estimate a scalar parameter that is constructed by averaging them. Since the odds ratio is not only a popular measure of association in case-control studies but also it is a sharp upper bound on causal relative risk, we pay special attention to semiparametrically efficient estimation of the expectation of the log odds ratio using the conditional distributions of the covariates that are identified in the data. Efficient estimation of the (log) odds ratio is a classical topic, but most papers take a parametric approach with a focus on robustness: see, e.g., Chen (2001), Tchetgen Tchetgen et al. (2010), and Tchetgen Tchetgen (2013. Our approach of targeting the nonparametrically aggregated versions of the odds ratio, which can be efficiently estimated via sieves (e.g., Chen (2007b)), offers a natural alternative. We derive the semiparametric efficiency bound for the aggregated log odds ratio and then propose an easy-to-implement sieve-based estimation algorithm. We also offer algorithms for causal inference if the true population distribution of the covariates is desirable for aggregation. Causal inference procedures are presented in detail in section 7, and an accompanying R package is available on the Comprehensive R Archive Network (CRAN) at https://CRAN.Rproject.org/package=ciccr. We revisit the datasets studied by Delavande & Zafar (2019) and Carvalho & Soares (2016) to illustrate how our methods can be used in case-control and casepopulation studies, respectively. The first example uses the data based on surveys of the students who entered a very selective university in Pakistan and those who did not, whereas the second example data combine a survey of drug-trafficking gangs in Rio de Janeiro with the 2000 Brazilian Census. Therefore, they correspond to the case-control and case-population designs, respectively. Using these datasets, we address new research questions that are not examined in the original papers: (i) the causal effect of attending private school on entering a very selective university and (ii) the causal impact of not staying in school on joining a criminal gang. In both of the examples, strong ignorability is implausible, but the MTR and MTS assump-tions can be reasonably well defended. Our results show that attending private high school increases the chance of entering a prestigious university only by a factor of less than 2 at the maximum: therefore, there is no substantial causal benefit here.
Also, our analysis on the Brazilian data shows that those who are not in school may have a higher chance of joining a criminal gang by a factor of 15 times in the worst case.
We now discuss the relation to the existing literature on causal inference and outcome-based sampling. Månsson et al. (2007) point out that the propensity score method has only limited ability to control for potential confounding factors in casecontrol studies. Our method does not rely on strong ignorability nor on the propensity score. Rose (2011) and Van der Laan & Rose (2011) propose a method of causal inference based on the assumption that the true case probability is known by a prior study. We focus on the case of unknown case probability; however, it is straightforward to modify our inference procedures if the case probability is indeed known. Didelez & Evans (2018) provide an excellent and extensive survey on causal inference under case-control sampling, but no discussion on partial identification approaches can be found there. Therefore, it appears to be a rather under-explored area to take an interval-identification approach to causal inference under outcomebased sampling. There are a couple of exceptions though. Kuroki et al. (2010) use linear and fractional programming techniques to bound the causal attributable and relative risk, respectively. It is noteworthy that they also consider the MTR assumption so that their lower bound on causal relative risk is simply one as in the current paper. However, their work is distinct from ours in that their upper bound on causal relative risk is obtained by assuming that there is prior knowledge about the lower bound on the true case probability; therefore, their upper bound is generally different from the usual odds ratio. Gabriel et al. (2020) focus on causal attributable risk and obtained bounds in a variety of scenarios including outcome-dependent sampling with an instrumental variable. But they do not leverage any monotonicity assumption. Therefore, our work is complementary to these existing papers. To the best of our knowledge, it was unknown in the literature that the odds ratio is the sharp upper bound of the identified interval of the causal relative risk when the MTR and MTS assumptions are imposed.
The remaining part of the paper is organized as follows. In section 2 we formally present the setup including the causal parameters of interest and the sampling scheme. Sections 3 to 5 focus on the causal relative risk and odds ratio to address identification, aggregation, and estimation issues. In section 6, we extend our results to the causal attributable risk. Section 7 covers how to carry out causal inference, and section 8 is for the applications. Throughout the paper, for generic random variables A and B, we will write f A and f A|B for the density of A and the conditional density of A given B.

Causal parameters
Let (Y * , T * , X * ) be a random vector of a binary outcome, binary treatment, and covariates of a representative individual. Since we are interested in case-control studies, we assume that a random sample of (Y * , T * , X * ) is not available. Instead, we have a sample of (Y, T, X), where the distribution of (T, X) given Y is related with that of (T * , X * ) given Y * . The exact sampling schemes and related assumptions will be discussed in detail later, but we only focus on the parameters of interest in this section.
For the sake of causal inference, we use the usual potential outcome notation.
So, Y * (t) will be the potential outcome for T * = t, and Y * can be written as Y * = Y * (1)T * + Y * (0)(1 − T * ). The causal effect of the treatment can be measured by (conditional) relative risk, which is defined by (1) Therefore, our notation extends Chen (2001) and Xie et al. (2020) by adding an extra layer of potential outcomes.
Alternatively, one may prefer measuring the causal effect of T * by the attributable risk, i.e.
However, it is θ(x), not θ AR (x), that turns out to be closely related with the odds ratio, which has been widely used as a measure of association in case-control studies.
For this reason we focus on θ(x) and its relationship with the odds ratio first, after which we extend our approach to θ AR (x) in section 6.

Bernoulli sampling
As we mentioned earlier, we assume that a random sample of (Y * , T * , X * ) is unavailable. Instead the researcher has access to a random sample of (Y, T, X), where the distribution of (Y, T, X) is related with that of (Y * , T * , X * ) by Bernoulli sampling (e.g. Breslow et al. 2000) that we describe below.
In Bernoulli sampling, the researcher first draws a Beroulli variable Y from a prespecified marginal distribution, after which she randomly draws (T, X) from some P y if and only if Y = y; so, Y is an artificial device to decide which subpopulation we will draw (T, X) from. If P y is the distribution of (T * , X * ) conditional on Y * = y, then this is nothing but case-control sampling. Since h 0 = P(Y = 1) is part of the sampling scheme, we will assume that it is known; if not, it can be easily estimated.
Before we proceed, we make a common support assumption for simplification.
Assumption A (Common Support). The support of X * and that of X given Y = y for y = 0, 1 coincide; the common support will be denoted by X .
Below we discuss two leading cases of Bernoulli sampling that we focus on throughout the paper.
Design 2 (Case-Population Sampling). P 0 represents the distribution of (T * , X * ) of the entire population, while P 1 is that of (T * , X * ) conditional on Y * = 1.
Design 1 is arguably the most popular form of case-control studies and design 2, which we call case-population sampling, is considered in Lancaster & Imbens (1996).
The latter has been used to study drug trafficking (Carvalho & Soares 2016) and mass demonstrations (Rosenfeld 2017) among others.
Note that the distribution of (T, X) is identified from the data, but that of (T * , X * ) x|0) or h 0 is the same as p 0 := P(Y * = 1), i.e. the true probability of the case in the population. Further, which yields the likelihood function studied in e.g. Manski & Lerman (1977). We emphasize that P(Y = 1|X = x) does not have structural interpretation like P(Y * = 1|X * = x), where the latter is often formed via domain knowledge in a specific field.

Identification of causal relative risk
In this section we study identification of θ(x), for which we first introduce some notation. For p ∈ [0, 1], define r(x, p) by under design 1, Further, let Π(t | y, x) := P(T = t | Y = y, X = x) be the retrospective binary regression function. Both r and Π depend on the distribution of (Y, T, X) and hence on the sampling design, but our notation is not explicit about it for simplicity. Define where we will implicitly assume that Π(t | y, x) = 0 for all t, y ∈ {0, 1} throughout.
The functions r and Γ are all identified because they are functionals of the joint distribution of (Y, T, X). In both designs, we have r(x, p 0 ) = p * (x) and r(x, 0) = 0, where p 0 := P(Y * = 1) and p * (x) := P(Y * = 1 | X * = x); here, p 0 is the only unidentified parameter in that if p 0 were known, then p * (x) would be identified as well. Note that Γ(x, 0) is nothing but the usual odds ratio.

Strong ignorability
Strong ignorability is a standard setup for causal inference, and it consists of the following two requirements.
Assumption B has the two requirements. The assumption that 0 < P(T * = 1 | X * = x) < 1 is the usual overlap condition that requires that treatment be nondegenerate for all x ∈ X . The condition that 0 < P{Y * (t) = 1 | X * = x} < 1 is needed here to avoid degenerate outcomes for all x ∈ X . Assumption C is the key condition for strong ignorability; if we control for the covariates X * , then the treatment assignment T * is independent of the potential outcomes. Below is the main implication in our context.
Then, for all x ∈ X and under design d ∈ {1, 2}, we have θ( Theorem 1 is closely related with Holland & Rubin (1988). Specifically, Holland & Rubin (1988) shows that under design 1, the odds ratio Γ(x, 0) is equal to the odds ratio in terms of the potential outcomes: i.e.
under strong ignorability. Theorem 1 reformulates this result in terms of causal relative risk, which has clearer interpretation. It also extends the same idea to the case of design 2.
Under design 2, θ(x) is point identified by the usual odds ratio but the case of design 1 is a bit different because p 0 is unidentified. However, this problem has been ignored because Γ(x, 0) is an approximation of Γ(x, p 0 ) when p 0 is close to zero by continuity; the assumption of small p 0 is known as the rare disease assumption in epidemiology. However, we remark that the approximation error is generally unrestricted: i.e.
where Π(t | y, x) = P(T * = t | X * = x, Y * = y) in design 1. Therefore, p 0 being close to zero restricts neither the sign nor the magnitude of ∂ p Γ(x, p) in a neighborhood of p = 0. Indeed, if T * is a rare treatment among the non-case population, or if it is an overly common treatment among the case population, then the rare-disease approximation can be poor; e.g. smoking can be fairly rare within the healthy population while it is less so among the population with lung cancer. To be more concrete, consider the case with no covariates: if Π(1 | 0) = 0.1, Π(1 | 1) = 0.7, and In other words, when there is no causal effect, we must have Γ(p 0 ) = 1, but Γ(0) will be about 2.4.
This problem has a quick solution though: since the function Γ(x, ·) itself is iden-tified, we can directly tell how good or bad the rare-disease approximation will be.
We formalize this idea by using the concept of partial identification.

Assumption D.
There is a known valuep such that p 0 ∈ [0,p].
The idea that the researcher can place an upper bound on an unidentified object has also been used in the context of robust estimation: see e.g. Horowitz & Manski (1995, 1997. Of course,p = 1 reflects the case where the researcher has no prior information for p 0 .
Theorem 2. Suppose that assumptions A to D are satisfied. Under design 1, we have , Γ(0,p)}, and the bounds are sharp.
it suffices to consider the two end points to obtain sharp bounds, where one of the end points is the odds ratio Γ(x, 0).
There is a special case to consider.
is potentially beneficial but it cannot hurt), then Γ(x, ·) is a decreasing function and hence we have Γ(x,p) ≤ θ(x) ≤ Γ(x, 0) under design 1; the odds ratio represents the maximum causal relative risk that is consistent with what is observed under design 1. If there is no information for p 0 , then the lower bound is simply one.
We note that design 2 provides an easier environment for causal inference. It seems ironic that design 2 was referred to as case-control sampling with contamination by Lancaster & Imbens (1996) but that the 'contamination' is in fact helpful for identification.

Beyond strong ignorability
Strong ignorability is a popular assumption for causal inference. But it does not deliver point identification under design 1 nor is it always satisfied in observational studies. We now consider alternative assumptions under which the treatment assignment is allowed to be endogenous while we can still obtain comparable bounds.
Assumption F (Monotone Treatment Selection). For all t ∈ {0, 1} and x ∈ X , Assumption E was first proposed by Manski (1997), while assumption F was used by Manski & Pepper (2000). Assumption E says that treatment is potentially beneficial but it never hurts. For instance, if an individual does not earn high income with a college degree, then the person will not be highly paid without a college degree, either. Assumption F says that, other things being equal, those who have a higher degree are at least as likely to earn high incomes, if their education attainment was randomly assigned, compared to those who did not have a higher degree.
So, in substance, the treatment decision chosen by an individual reveals the 'type' of the person; those who choose to obtain a higher degree are more motivated and they would not be any less likely to earn high incomes than those who choose not to obtain a higher degree if they were randomly assigned to a different treatment status. Assumption F is trivially weaker than assumption C, and it allows individuals with 'higher ability' to self-select a higher degree.
Theorem 3. Suppose that assumptions A, B, E and F are satisfied. Then, under both designs 1 and 2, we have 1 ≤ θ(x) ≤ Γ(x, 0), where the bounds are sharp.
The sharp trivial lower bound follows from assumption E. The upper bound is a consequence of assumption F. It is also noteworthy that the bounds in theorem 3 do not require the rare-disease assumption, or assumption D.
Theorem 3 can be compared with theorems 1 and 2. Under design 2, strong ignorability is informative in that it ensures that the odds ratio point identifies the causal parameter θ(x). However, under design 1, we only obtain interval identification, whether we impose strong ignorability or monotonicity; the odds ratio will be the sharp upper bound on θ(x). The empirical content of assumptions E and F does not depend on which of the two Bernoulli sampling schemes is used. Therefore, with the causal parameter θ(x), or log{θ(x)}, in mind, the odds ratio Γ(x, 0), or its logarithm, is a natural estimand to focus on. If the sample available is from design 2, then it is relevant how the researcher views assumption C versus assumption F. However, if the sample is from design 1, i.e. case-controlled with no 'contamination,' then it is not so much useful to impose assumption C compared to using assumption F in learning the potential maximum benefit of the treatment.
In what follows we will take theorem 3 as our basis for causal inference; using strong ignorability is either easier or similar. From hereon we will write OR(x) := Γ(x, 0) to emphasize that this is the usual odds ratio conditional on X = x.

The odds ratio, heterogeneity, and aggregation
Since we are conditioning on a specific value of the covariate vector, theorem 3 is the most general approach to deal with potential heterogeneity in the treatment effect.
However, log OR(x) is generally difficult to estimate with high precision when the dimension of X * is high.
To avoid the curse of dimensionality, it is popular in case-control studies to adopt logistic regression at the true population level, which also explains why the convention of taking logarithm has become popular. One can alternatively parametrize the odds ratio function itself: see e.g. Chen (2007a) and Tchetgen Tchetgen (2013).
Parametric assumptions are convenient, but they are restrictive; log{OR(x)} is generally an unknown function of x that can be highly nonlinear. Instead of introducing any parametrization, we can obtain a robust summary measure by aggregating over the population distribution of the covariates, i.e.θ : and the bounds are sharp under the conditions of theorem 3. Aggregation can be done by using a different weight function, but it seems the most natural to use the true population distribution of the covariates.
However, X * is not always observed and hence this type of aggregation is not always feasible. We start with feasible aggregation: for y = 0, 1, define where F X|Y (· | y) is the distribution of X given Y = y under Bernoulli sampling.
Then, β(y) is an identified object, and under design d ∈ {1, 2}, we have Therefore, case-population sampling makes aggregation simpler as well.

Efficient estimation of β(y)
Before we study inferential issues, we discuss efficient estimation of β(y). For this purpose, we point out that the sample consists of independent and identically distributed copies of (Y, T, X); the sampling designs affect the distribution of (Y, T, X) and its relationship with that of (Y * , T * , X * ). All regularity conditions and results in this section will be presented in terms of the observed variables (Y, T, X); therefore, the regularity conditions will be testable in principle.

The efficient influence function
We first derive the semiparametric efficiency bound. We start with the following assumptions for regularity.

Assumption G (Bounded Probabilities).
There is a constant ε > 0 such that for each Assumption H (Regular Distribution). The distribution function F X|Y has a probability density f X|Y that satisfies 0 < f X|Y (x|y) < ∞ for all x ∈ X and y = 0, 1.
Assumption G is slightly stronger than what we need to derive the efficient influence function but it is useful to ensure that all the population quantities given below are well defined without spelling out all the moment conditions. Assumption H focuses on the case where X is continuous but this is only for the sake of notational simplicity.
Under Bernoulli samping, the likelihood of a single observation (Y, T, X) can be expressed as a mixture of two binary likelihoods, from which we first have the following lemma.
Lemma 1. Consider the Bernoulli sampling scheme of design 1 or design 2. The tangent space can be represented by the set of functions of the following form: where the functions a y and b y are such that E{a y (X)|Y = y} = 0 and E{s 2 (Y, T, X)} < ∞ for each y = 0, 1.
By direct calculation, as in Hahn (1998), we can show that β(y) is pathwise differentiable along regular parametric submodels in the sense of Newey (1990Newey ( , 1994. Further, it turns out that the pathwise derivative is an element of the tangent space presented in lemma 1, from which we can obtain the semiparametric efficiency bound for β(y). The following theorem presents this result. Let where the second equality is by the Bayes rule. Further, for y = 0, 1, define Theorem 4. Suppose that assumptions A, G and H hold and that we have a sample by Bernoulli sampling. Then, for y = 0, 1, β(y) is pathwise differentiable and its pathwise Further, F y is an element of the tangent space, and therefore, the semiparametric efficiency bound for β(y) is given by E F 2 y (Y, T, X) .
Theorem 4 implies that the asymptotic variance of a √ n-consistent and asymptotically linear estimator of β(y) should be at least E{F 2 y (Y, T, X)} by Theorem 2.1 of Newey (1994). The first term that appears in F y (Y, T, X) has mean zero, because The other terms in F y (Y, T, X) are for adjustment to address the effect of first step nonparametric estimation of log OR(X) via P(T = 1|X = x, Y = y).

Estimation algorithms
Efficient estimators of β(y) for y = 0, 1 can be constructed in multiple ways. The most straightforward approach is using equation (7); i.e. we base an estimator on the moment condition β(y) = E Y y (1 − Y) 1−y log OR(X) /{h y 0 (1 − h 0 ) 1−y }, where we plug in a nonparametric estimator of OR(x). If the resulting estimator is √ nconsistent and asymptotically linear, then its asymptotic variance will be given by E{F 2 y (Y, T, X)}, as we commented earlier. Below we propose an algorithm that implements this idea, for which we use sieve logistic estimators for the first step nonparametric estimation.
Suppose that we have an i.i.d. sample, (Y i , T i , X i ) : i = 1, . . . , n . Throughout the discussion we assume that h 0 is known; otherwise, we can useĥ := ∑ n i=1 Y i /n instead, which does not affect the first order asymptotics, provided that the distri-bution of (T, X) given Y = y does not depend on h 0 .
In order to estimate OR(x) nonparametrically in the first step, we consider infinite dimensional (retrospective) logistic regression: i.e. for y = 0, 1, where {φ j : j = 1, 2, . . .} is a series of basis functions and {µ j,y : j = 1, 2, . . .} is a series of unknown coefficients for each y = 0, 1. It then follows that log OR( provided that J n diverges as n increases. Equation (9) suggests the following twostep sieve estimation strategy: i. In the first step, for each y = 0, 1, estimate {µ j,y : y = 0, 1 j = 1, . . . , J n } by logistic regression of T i on {φ j (X i ) : j = 1, . . . , J n } with the Y i = y sample.
ii. In the second step, construct a sample analog of equation (9): i.e.

β(y)
where µ j,y 's are sieve logit estimates from the first step and Since we use retrospective regression as shown in equation (8), we call the estimator defined in (10) the retrospective sieve logistic estimator of β(y), y = 0, 1. It can be computed using standard software for logistic regression, as described in algorithm 1.
The procedure described in algorithm 1 achieves the first step by running a combined logistic regression of T i on Y i , the sieve basis terms and the interactions be-

Algorithm 1: Retrospective Sieve Logistic Estimator of β(1)
. . , n}, tuning parameter J n and basis functions {φ j (·) : j = 1, . . . , J n } Output: estimate of β(1) and its standard error 1 Construct {φ 1 (X i ), . . . , φ J n (X i ) : i = 1, . . . , n}, where an intercept term is excluded in φ j 's; 2 For each j = 1, . . . , J n , compute the empirical mean of φ j (X i ) using only the case sample (Y i = 1) and construct the demeaned version, say ϕ j (X i ), of φ j (X i ); 3 Run a logistic regression of T i on the following regressors: an intercept term, Y i , ϕ j (X i ), j = 1, . . . , J n , and interactions between Y i and ϕ j (X i ), j = 1, . . . , J n , using standard software; 4 Read off the estimated coefficient for Y i and its standard error tween Y i and the sieve basis terms. This is first-order equivalent since Y i is binary and full interaction terms are included. For the second step, instead of evaluating the right-hand side of equation (10) after logistic regression, φ j (X i )'s are demeaned first using only the case sample so that the resulting coefficient for Y i is first-order equivalent to the estimator defined in equation (10). The advantage of the formulation in algorithm 1 is that the standard error of β(1) can be read off directly from standard software without any further programming. It is straightforward to modify algorithm 1 for estimating β(0). One has to compute the empirical mean of φ j (X i ) using only the control sample (Y i = 0) for the demeaning step.
It is not difficult to work out formal asymptotic properties of our proposed sieve estimator in view of the well-established literature on two-step sieve estimation (see, e.g., Ai & Chen 2003, Ackerberg et al. 2014, among many others). Since this is now well understood in the literature, we omit details for brevity of the paper.
Appendix B reports the results of a small Monte Carlo experiment that illustrates the finite-sample performance of the proposed estimators of β(1) and β(0).

Identification of attributable risk
In this section we present identification results for the alternative causal parameter θ AR (x) defined in equation (2) under the conditions we discussed in section 3.

Define
where Π(t | y, x) and r(x, p) are defined in section 3. Note that Γ AR (x, 0) is not the odds ratio but is the difference of two probability ratios.
Theorem 5. Suppose that assumptions A to C are satisfied. Then, for all x ∈ X and under Therefore, under strong ignorability, unlike θ(x), θ AR (x) depends on p 0 in both designs 1 and 2. Further, the rare-disease approximation does not provide anything useful because if p 0 ≈ 0, then r(x, p 0 ) ≈ r(x, 0) = 0 by continuity. However, the partial identification approach is still valid.
Theorem 6 is a simple corollary of theorem 5. The sharp bounds for the aggregated parameterθ AR := X θ AR (x)ω(x)ds for some weight function ω can be obtained by taking max/min after aggregation.
Unlike the case of θ(x), strong ignorability does not lead to point identification under either design 1 or 2. What is similar though is that we obtain partial identification and that the bounds under strong ignorability can be shown to be quite comparable to those under the monotonicity assumptions. The sharp upper bound in theorem 7 is the same as the one presented in theorem 6. Therefore, replacing strong ignorability with assumptions E and F is not costly in terms of the sharp upper bound on θ AR (x). Also, similarly to the case of θ(x), the trivial bound of 0 in theorem 7 is a consequence of assumption E.

Causal inference on relative and attributable risk
In this section we discuss how to carry out causal inference on relative risk (RR) and attributable risk (AR) under the MTR and MTS assumptions. In our discussion below, z(1 − α) will be the 1 − α quantile of the standard normal distribution.
First, we focus on RR, for which we consider the parameter of interest defined by exp(θ), whereθ := E{log θ(X * )}: the average of the logarithm of RR is less likely to be affected unduly by outliers than that of RR itself. See Appendix A for further discussions. We propose to use equation (5) So, causal inference under design 2 follows immediately from section 5: i.e. the 1 − α one-sided confidence interval for exp(θ) can be constructed by the interval between one and exp β(0) + z(1 − α) s(0) , where s(0) is the standard error of β(0).
We now turn to causal inference on AR. We start with defining β AR (p, y; d) := indicates the underlying sampling design. Then, the identification analysis in section 6 shows that the strong ignorability assumptions lead to the following equality: under design d ∈ {1, 2}, where β(p, y; d) is an identified object for all (p, y) ∈ [0, 1] × {0, 1}. Further, if the strong ignorability assumptions are replaced with the MTR and MTS, then the righthand side of equation (13) becomes an upper bound, while the lower bound is simply zero.
To appreciate the right-hand side of equation (13) (as the aggregated AR or its upper bound), we first consider the simpler case of design 2. Unlike the RR, even under design 2, it is not sufficient to estimate the retrospective regression. Specifically, β AR (p, 0; 2) = pξ CP , where the sample analog of ξ CP is given by where P(Y = y | X i ) and Π(t | y, X i ) are parametric or sieve logit estimators; here, h 0 is replaced with the sample mean of Y i . In principle we can analytically work out the asymptotic standard error of ξ CP , on which we can base our inference.
Alternatively, we may use the bootstrap instead. For example, the (1 − α) confidence interval for E{θ AR (X * )} under MTR and MTS can be obtained by using a (onesided) uniform confidence band in p that has the following form: We make a few comments. The researcher may adopt assumption D by restricting the on [0,p]. Asymptotic validity of the nonparametric bootstrap in two-step semiparametric models is a well-studied topic (e.g., Chen et al. 2003). However, in practice, the naïve bootstrap may suffer from a finite sample bias because ratios of probabilities are estimated in the first step. To mitigate this issue, we recommend using Efron (1982)'s bias-corrected one-sided percentile interval to obtain The case of design 1 can be handled by the sample principle, although β AR (p, y; 1) has a bit more complicated form; nonlinearity in p makes it difficult to obtain a uniform confidence band in p. We propose using one-sided pointwise confidence intervals using Efron's bias-corrected percentile intervals in this case. Computational details regarding causal inference on attributable risk are given in Algorithm 2. In describing the algorithm, we focus on design 1; in the case of design 2, we replace the upper bound estimates UB AR (p) with those of pξ CP , and the resulting confidence intervals will be uniform in p ∈ [0, 1].
2 For each p ∈ P, evaluate sample analogs UB AR (p) of UB AR (p) := (1 − p)β AR (p, 0; 1) + pβ AR (p, 1; 1); in this step we need to compute retrospective estimates of Π(t | y, X i ) for t = 0, 1, y = 0, 1 as well as prospective estimates of P(Y = 1 | X i ) because β AR (p, y; 1) depends on r(x, p) as its definition, provided right above equation (13) AR (p) for each p ∈ P; 4 For each p ∈ P, compute where 1{·} is the usual indicator function; 5 For each p ∈ P, obtain ν * (p) : is the cumulative distribution function of the standard normal random variable; (2019). This is survey data from male students who were already enrolled in different types of universities in Pakistan, all located in Islamabad/Rawalpindi and Lahore. Delavande & Zafar (2019) include two Western-style universities, one Islamic university, and four madrassas, but we focus on the two Western-style ones in our analysis: between the two universities, Delavande & Zafar (2019) call the more expensive, selective, and reputable university "Very Selective University" (VSU) and the other simply "Selective University" (SU). Therefore, we restrict the population of interest to those who entered either VSU or SU, and we define the binary outcome to be whether a student entered VSU. The binary treatment we consider is whether a student attended private school before university. Since the students in the sample were already enrolled in either VSU or SU at the time of the survey, we have a case-control sample, i.e. our design 1.  Table 1 shows the likelihood of entering VSU by private school attendance before university; we will discuss controlling for covariates later. The empirical odds ratio is 1.38.
In this example, the unconfoundedness assumption is unlikely to hold, because those who attended private school before university are likely to have more resourceful parents. This concern may not completely disappear even if we control for parental income and wealth because of the presence of unobserved parental abili-  We now consider the methods described in section 7, i.e. causal inference on the aggregated relative and attributable risk (RR and AR, respectively) in terms of the population distribution of the covariates. We rely on the MTR and MTS assumptions to interpret our results as upper bounds. Also, we comment that we use a less demanding specification for AR, because the estimand for AR is much more complex and the bootstrap is used for causal inference. Specifically, we only included an indicator for at least one college-educated parent and parents' monthly income.
The number of the bootstrap replications was 10,000.  Notes. Each entry shows the sample mean. Parents' monthly income is in thousands of rupees and all other variables are binary indicator variables. The case and control samples consist of those who entered a very selective university (VSU) and a selective university (SU), respectively. Note. The left panel shows the estimates and the 95% one-sided uniform confidence band for the upper bounds on relative risk and the right panel the estimates and the 95% one-sided pointwise confidence intervals for the upper bounds on attributable risk, as functions of the unknown true case probability, i.e., P(Y * = 1).
at most 1.21. Even in terms of the confidence intervals, it seems highly unlikely that the impact is more than a factor of 2. The right panel of figure 1 shows AR.
The graph shows an inverted U-shape, because r(x, p)Γ AR (x, p) = 0 whenever p is either 0 or 1. The maximum point estimate of the upper bound is 0.044, while the maximum value of the confidence intervals is 0.153. Therefore, it seems highly unlikely that attending private school increases the chance of entering VSU by more than 16 percent.
None of our results require strong ignorability or the rare-disease assumption.

Case-population sampling: joining a criminal gang
We revisit Carvalho & Soares (2016), who combine the 2000 Brazilian Census with a unique survey of drug-trafficking gangs in favelas (slums) of Rio de Janeiro; therefore, their dataset is an example of case-population sampling, i.e. our design 2. In their study, they use the method of Lancaster & Imbens (1996)  and with no religious affiliation are more likely to join drug-trafficking gangs." Table 4 provides summary statistics of the sample. We regard currently not attending school as the treatment variable of interest. Unconfoundedness is not plausible because of the endogeneity of schooling that we mentioned earlier. Furthermore, it is plausible that unmeasured factors such as family support could affect both treatment and outcome. However, not being in school may increase the chance of exposure to gang-related activities, and those who chose to be in school may be the ones who care for consequences no less than those who chose not to be; therefore, the MTR and MTS follow, respectively.  Notes. Each entry shows the sample mean. Age is in years and all other variables are binary indicator variables. The population consists of men aged 10-25 living in Rio's Favelas.  The uniform confidence band is based on 1,000 bootstrap replications. Note that the confidence band is truncated at one, because the AR cannot be larger than one.
Overall, our results are suggestive of potentially large impacts of keeping young men in school in order to discourage them to participate in criminal activities. Further research based on careful study designs would be necessary to reach a more definitive answer.

Appendices to "Causal inference under outcome-based sampling with monotonicity assumptions"
In appendices A and B we discuss aggregation of the odds ratio without taking the logarithm and present the results of a small Monte Carlo experiment. Appendix C present proofs.

A Averaging without taking the logarithm
In the main text we followed the convention of using the logarithm of the odds ratio, and we focused on an aggregated version of the logarithm of the odds ratio, i.e.
β(y) = E log{OR(X)} | Y = y for y = 0, 1. As a result, the central causal parameter in the main text was the logarithm of relative risk.
Alternatively, one may want to proceed without taking the logarithm, which does not change the substance of our results, though we now need to consider Bernoulli sampling. Then, for y = 0, 1, κ(y) is pathwise differentiable and its pathwise A-1 derivative is given by Further, K y is an element of the tangent space, and therefore, the semiparametric efficiency bound for κ(y) is given by E K 2 y (Y, T, X) .
We can construct efficient estimators of κ(y) and carry out causal inference on ζ by using the same idea as we described in section 5.2. We do not repeat all the details for brevity.
In general we have E{log OR(X * )} ≤ log E{OR(X * )} by Jensen's inequality.
Therefore, an average of the log odds ratio is less likely to be affected unduly by outliers than that of the odds ratio itself. This seems to be another merit in using the logarithm of the odds ratio in addition to the usual advantage that it corresponds to the coefficients of the treatment variable when a parametric logistic model is used.
There were 1,000 Monte Carlo replications. We consider two estimators: (i) a retrospective parametric logistic estimator that uses X as covariates and (ii) a retrospective sieve logistic estimator that uses the linear, quadratic and interaction terms of X as covariates (that is, 2d x + d x (d x − 1)/2 = 20 covariates all together).  (0). It shows almost no bias and small root mean squared errors and absolute deviations. Its coverage probability is close to the nominal 95%. The sieve estimator exhibits some positive biases but its performance is overall satisfactory.