EconBase
← Back to paper

Statistical Tests for Replacing Human Decision Makers with Algorithms

Extracted main text — title through conclusion, appendix excluded. This is what our citation measures are computed over, published so the extraction can be checked by eye.

209,379 characters · 18 sections · 153 citation commands

Rendered from LaTeX for readability, not typeset faithfully. Citation keys are highlighted; maths is left as source; figures, tables and equation environments are summarised rather than reproduced; unrecognised commands are greyed out so nothing is silently dropped. Email addresses are removed.

Statistical tests for replacing human decision makers with algorithms

\thispagestyle{empty}

abstract{\sc Abstract.} This paper proposes a statistical framework of using artificial intelligence to improve human decision making. The performance of each human decision maker is benchmarked against that of machine predictions. We replace the diagnoses made by a subset of the decision makers with the recommendation from the machine learning algorithm. We apply both a heuristic frequentist approach and a Bayesian posterior loss function approach to abnormal birth detection using a nationwide dataset of doctor diagnoses from prepregnancy checkups of reproductive age couples and pregnancy outcomes. We find that our algorithm on a test dataset results in a higher overall true positive rate and a lower false positive rate than the diagnoses made by doctors only. {\sc Keywords}: Artificial Intelligence, Machine Learning, Decision Making, ROC Curve \\ JEL Classification: C44, C11, C12

Introduction

comment\textcolor{cyan}{ In the current era of machine learning, artificial intelligence (AI) algorithms have emerged as valuable tools that can learn significant features from data, thereby showing potential for facilitating decision making in various disciplines. To mention a few, gulshan2016development used a deep learning algorithm to detect diabetic retinopathy in retinal fundus photographs; castro2017large applied natural language processing techniques to electronic medical records to identify patients with cerebral aneurysms. In the field of bank lending, fuster2022predictably leveraged machine learning algorithms to predict default probability for lending decision. berk2017impact applied machine learning predictions to parole release decisions.}

\setcounter{page}{1} In the current era of machine learning, artificial intelligence (AI) algorithms have emerged as valuable tools that can learn significant features from data and potentially facilitate decision making in various disciplines. In medical research, esteva2017dermatologist and kermany1 utilize deep neural network to automate diagnosis based on medical images. berg2020rise and sadhwani2021deep leverage machine learning algorithms to predict the default probability for bank lending decision. mullainathan2017machine and athey2019machine apply machine learning models to broad optimal policy assignment problems.

A considerable number of papers have compared the performance of algorithms with that of the representative human decision makers. To mention a few, esteva2017dermatologist claims that their algorithm outperformed the aggregate dermatologist on some skin cancer classification tasks; kermany1 targets macular degeneration dagnosis and concluded that the machine algorithm outperforms some retinologists; rajpurkar1 highlights the performance gain of a deep convolutional neural network over an aggregate cardiologist for processing ECG sequences; QJEbail trains a gradient boosted decision tree model to predict crime risk during pre-trial bail and suggested that substituting human judges with the algorithm could result in large welfare gains.

comment{\color{orange}{Our paper makes several contributions to the related literature. First, we offer a conceptual framework of information and incentives for interpreting comparisons between the machine algorithms and human decision makers. Machine algorithms provide information, but decision making is a combination of incentives and information. Using machine algorithms to assist with decision making necessitates the modeling of incentives. Second, we provide a theoretical model that allows us to identify human decision makers that are candidates of replacement by machine algorithms and to generate machine algorithm based decision that incorporates human decision maker preferences. The replacement model also accounts for the sampling uncertainty of individual decision makers. Third, we conduct an extensive synthetic data analysis that serves as guidance for evaluating empirical data in the presence of complementarity and information asymmetry between human decision maker and machine algorithms. Fourth, our empirical application to abnormal birth detection demonstrate that the proposed replacement algorithm significantly improves the overall performance of risky pregnancy detection. }}

The findings of the aforementioned literature rely mostly on the observation that the pair of false positive rate (FPR) and true positive rate (TPR) point lies strictly below the receiver operating characteristic (ROC) curve generated by the machine learning algorithm, implying that algorithms can achieve a higher TPR for a given FPR or a lower FPR for a given TPR. In binary classification / decision making, FPR is the number of wrongly classified negative events divided by the number of actual negative events, and TPR is the number of correctly classified positive events divided by the number of total positive events. FPR/TPR are synonymous to size and power in classical hypothesis testing.

commentTypically, an algorithm first learns a propensity score function $p\(x\right)$ from data, then applies the decision rule $\mathds{1}\(p\(x\right) > c\right)$ to compute the FPR/TPR pair, where $c$ is a cutoff threshold. The machine ROC curve is generated by varying the cutoff thresholds $c$. Utilizing historical data, the aggregate sample FPR/TPR point for human decision makers can also be calculated.

We first caution against such interpretations without a deeper understanding of human decision making processes. The literature findings can be rationalized not only by the superior information quality of algorithms but also by the incentive heterogeneity, i.e. the differential preferences for taking the same action by multiple human decision makers, some of whom can be no less accurate than algorithms in processing information from observational data. Machine algorithms provide information, but decision making is a combination of incentives and information. Using machine algorithms to assist with decision making necessitates the modeling of incentives. Second, the FPR/TPR pairs of human decision makers are typically imprecisely measured, especially when the number of cases for each decision makers is not large. The data in our empirical analysis shows not only substantial heterogeneity between individual doctors, but also that the randomness in measuring the quality of decision makers plays a key role when the performance of decision makers is compared to that of machine algorithms.

To illustrate the first issue of concern, consider Figure (ref), in which a collection of FPR/TPR pairs for human decision makers, denoted as $j = 1, \ldots, J$, all lie approximately on a ROC curve generated by their employed decision rules $\widehat Y_{i,j} = \mathds{1}\(p\(X_{i,j}, U_{i,j}\right) > c_{j}\right)$ with different individual cutoff threshold $c_{j}$ for decision maker $j$. In the decision rule, $X_{i,j}$ are observed features used in the machine learning algorithm; $U_{i,j}$ are private information only observable to the human decision makers, and $p\(x,u\right) = \mathbb{P}\(Y = 1\vert x,u\right)$ is a propensity score function. Also drawn is the machine ROC curve based on classification rules $\widehat Y_i = \mathds{1}\(p\(X_i\right) > c\right)$, which collects the corresponding FPR/TPR pairs by varying the cutoff threshold $c$, and where $p\(x\right) = \mathbb{P}\(Y = 1\vert x\right)$ is the correctly specified propensity score function using observable features $x$ discovered by the machine learning algorithm. However, after averaging over all decision makers, the aggregate human FPR/TPR point lies visibly below the machine ROC curve.

figure[figure omitted — 852 chars of source]

Our paper makes several contributions. First, we offer a conceptual framework of information and incentives for interpreting comparisons between the machine algorithms and human decision makers. Second, we provide a model to identify human decision maker candidates for replacement by machine algorithms and to generate machine algorithm based decisions that incorporate human decision maker preferences. The replacement model accounts for the sampling uncertainty of individual decision makers. Third, an empirical application to abnormal birth detection demonstrates that our proposed replacement algorithm significantly improves the overall performance of risky pregnancy detection. Fourth, we conduct an extensive synthetic data analysis that serves as guidance for evaluating empirical procedures incorporating complementarity in the presence of information asymmetry between human decision maker and machine algorithms.

In this paper, in order to compare machines with human decision makers, we restrict incentive heterogeneity and focus on information processing capacity. If the individual FPR/TPR pairs are precisely known without sampling errors, they can be directly compared to the machine ROC curve; we interpret a human FPR/TPR pair below the machine ROC curve as evidence of the superiority of the machine algorithms. As shown in Figure (ref), a human FPR/TPR pair below the machine ROC curve can be dominated by any point on the line segment of the ROC curve between A and B. Replacing the human FPR/TPR pair by any point on the A-B segment of the machine ROC curve segment results in higher TPR without increasing FPR, or lower FPR without sacrificing TPR.

In reality, only an estimate of the FPR/TPR pair can be obtained from the empirical data. A statistical framework to compare the performance of algorithms with that of human decision makers requires accounting for estimation sampling errors. We focus on two main issues. First, we seek statistical evidence supporting the information superiority of an algorithm that favors the replacement of a human decision maker. Second, we aim to identify the most appropriate point on the machine ROC curve for this purpose. To address these two issues, we experiment with both a heuristic frequentist confidence set approach and a subsequent Bayesian inference approach. In both scenarios, confidence and credible regions are formed to inform the decision making process. The Bayesian approach results in more replacement and additional improvement in the aggregate FPR/TPR pair. We suggest the Bayesian analysis as an applicable decision framework.

At a disaggregated level, each individual human can have either less or more information processing capacity than an algorithm has. For instance, liang_evaluation_2019 proposes a machine learning algorithm to diagnose childhood diseases that outperforms junior physician groups but marginally underperforms senior physician groups.

commentliang_evaluation_2019 proposes a machine learning algorithm to diagnose childhood diseases. A comparison of the algorithm with physicians shows that the authors' model outperforms the junior physician groups but marginally underperforms senior physician groups.

Similar findings are reported in peng2021deep. esteva2017dermatologist and kermany1 also find substantial variability in the human experts' performance. Our framework chooses between each human decision maker and the algorithm for making future decisions. We identify a subset of human decision makers to be replaced by the algorithm, whereas the rest of human decision makers are retained.

commentIt is implemented through a human-algorithm mixed decision rule under which a part of identified human decision makers are replaced by the algorithm, whereas the rest of human decision makers are retained. The eventual future decision making is done through a combination of remaining human decision makers and the algorithm.

We apply our statistical framework to a unique National Free Prepregnancy Checkups (NFPC) dataset. The NFPC is a free health checkup service for conceiving couples across 31 provinces in China. In addition to the pregnancy outcome and numerous patient-case features, the dataset also includes the doctors' IDs and diagnoses of adverse pregnancy outcomes. We first split the data into two parts. The first part is used to compare doctors with algorithms. Specifically, we employ a random forest (RF) method for diagnosing risky pregnancy, which achieves an area under the curve (AUC) above 0.68. Using 95% credible level, our Bayesian approach suggests that the random forest algorithm outperforms 46.1% of doctors. The second part of the dataset is used to evaluate the quality of the diagnosis procedure based on the combination of retained doctors and the algorithm. The combined decision making procedure achieves an increase of 46.6% in the TPR and a reduction of 10.1% in the FPR. Additional detailed analysis further shows that the potential for machine algorithms to improve decision making quality is substantial even when only a smaller portion of doctors are replaced. We also find that doctors practicing only in country hospitals have a lower replacement ratio compared with those having practiced in township clinics. The result of our Bayesian analysis suggests that 51.2% of doctors who have practiced only at township clinics are replaced compared to 39.8% of doctors who have practiced only at county hospitals.

\paragraph{Related Literature} Our paper relates to several strands of literature. An extensive literature studies the utilization of AI to enhance medical diagnostic capabilities. Machine learning, especially deep learning methods, which demonstrate great potential in tackling diverse and complex tasks, has been experimented to diagnose in multiple medical subfields, including ophthalmology kermany1; cardiology rajpurkar1, hannun2019cardiologist; dermatology esteva2017dermatologist; respirology ardila2019end, liang_evaluation_2019; clinical psychology and psychiatry ashar2017empathic, yoon2022d; tumor and cancer detection mckinney2020international, peng2021deep, uhm2021deep, tian2024prediction. Additional surveys can be found in erickson2017machine, johnson2018artificial, dwyer2018machine, chan2020machine, huang2020fusion and swanson2023patterns.

Beyond medical diagnoses, AI is widely explored in social-economic decision making. See for example berg2020rise, sadhwani2021deep and fekadu2022machine for loan approval and credit risk modeling; fuster2019role, vallee2019marketplace and fuster2022predictably for market structure implications of employing machine learning algorithms; berk2017impact, zeng2017interpretable, QJEbail for bail and parole analysis; chalfin2016productivity and sajjadiani2019using for productivity assessment.

Numerous papers in the literature have benchmark algorithms against human decision makers\footnote{ See for example long2017artificial, kermany1, de2018clinically, rajpurkar1, hannun2019cardiologist, esteva2017dermatologist, han2020augmented, daneshjou2022disparities, ardila2019end, liang_evaluation_2019, mckinney2020international, peng2021deep, uhm2021deep, tian2024prediction, berk2017impact, QJEbail, han2020augmented. }. While machine algorithms often outperform some aggregation of human decision makers, these findings are not uniform across individual human decision makers. Unlike machine algorithms, human decision makers can be highly heterogeneous in both incentives and information processing capacity. The health economics literature suggests that doctors may be swayed by multiple non-medical incentives including lawsuit avoidance studdert2005defensive, financial gain johnson2016physicians, demand pressure from patient lopez2018contribution and procedural skills currie3. Our analysis highlights the importance of modeling and restricting incentive heterogeneity in a human-AI comparison.

A growing literature also explores AI assisted human decision making. While brennan2019comparing, han2020augmented, peng2021deep, yang2021deep and tian2024prediction report salient performance improvement when doctors can refer to the prediction results of algorithms, jin2024evaluating and yu2024heterogeneity report contradicting evidence where the performance of a portion of doctors is worsened by AI assistance. By offering doctors monetary incentives prior to the experiment, wang2023diagnosing and wang2024overcoming find that doctor diagnoses can be significantly influenced by both the machine information and the preset incentive structures. While both bansal2021does and wang2023diagnosing find that giving doctors explanations increases the acceptance of machine recommendations, the effect of providing explanation on performance is inconclusive and varies. In the beverage vending machine business, a field experiment on product assortment decision conducted by kawaguchi2021will finds heterogeneous adoption by workers dependent on location and both worker and machine characteristics. alur2023auditing propose a test whether human experts help improve machine algorithm predictions. Our analysis also suggests that the human machine complementarity, argued for by donahue2022human, is not only theoretically challenging but also difficult to implement empirically. Overall, the mechanism by which AI assists human decision making is unclear. Our paper thus focuses on a simple strategy that identifies and replaces underperforming doctors. This modeling choice is also consistent with the analysis in mullainathan2022diagnosing and chan2022selection who suggest that doctor performance can not be explained by preference heterogeneity alone. In addition, the case-specific replacement algorithm described in Appendix (ref) does not outperform the baseline method for our NFPC dataset.

A substantial body of literature discusses the discriminatory bias of algorithms o2017weapons, eubanks2018automating, berk2021fairness. But the potential of AI and algorithmic decision making to reverse extant bias in the training data is also noted by rambachan2019bias and rambachan2020economic. Through efficent information provision and scarce resource utilization, AI can be instrumental for inequality reduction. Using artificial intelligence to empower medical diagnose in developing areas has been advocated by researches including adepoju2017mhealth, guo2018application, trivedi2019risks, mondal2023artificial and others. bulathwela2021could discuss the comprehensive application of AI to narrow education inequality gap. Our finding using the NFPC dataset is also consistent with anecdotal information regarding the quality disparity across tiers of the hospital classification system in China.

commentBeyond medical diagnoses, berk2017impact, zeng2017interpretable, QJEbail and fuster2022predictably, among others, investigate the use of AI in social-economic decision making, including loan approval, bail, and parole. \textcolor{blue}{FinTech companies increasingly use accessible digital information to to predict individuals' behaviors(berg2020rise) fuster2019role study FinTech lending in the U.S. mortgage market, implying that FinTech lenders are mostly competing with the traditional mortgage lenders instead of expanding access. vallee2019marketplace and tang2019peer extend this view to peer-to-peer (P2P) lending market. fuster2022predictably discuss the effect of machine learning on interest rates in various groups at an equilibrium, under a static model. sadhwani2021deep and le2018predicting apply machine learning to credit risk modeling and banking. }
comment{\color{blue}{There is a substantial body of literature discussing the fairness of algorithms. It has been discussed in some books. (eubanks2018automating, o2017weapons) Articles find that in terms of race, in judicial proceedings, blacks are disproportionately likely to receive monetary bail rather than being released without bail, and they are more likely to be assigned higher monetary bail if they are granted bail. (arnold2018racial,arnold2022measuring) Even if an algorithm does not expressly rely on race, some paper discuss that Algorithmic risk assessment in bail will unfairly deny racial minorities bail, because of racial bias in earlier stages of criminal justice. (chouldechova2017fair, berk2021fairness, starr2014evidence) There are also some articles focusing on the gender (kay2015unequal, bolukbasi2016man, zhao2018gender) and education (baker2021algorithmic, hutchinson201950, kizilcec2022algorithmic) Our article primarily discusses the comparsion and complementarity of algorithmic decision making and human decision making, which is distinctly different from the articles above. }}
comment{\color{cyan}{In the medical field, there are many articles using machine learning to help to predict or discriminate various kinds of diseases, for heart attack (mullainathan2022diagnosing, ali2021heart), for kidney disease(kshirsagar2008simple), for dementia(li2018data,maroco2011data), for COVID-19 (kwekha2023coronavirus, alimadadi2020artificial). uddin2019comparing offers a comprehensive review comparing the performance of various types of supervised machine learning algorithms in predicting diseases. In the field of psychology, there are also abundant studies (yarkoni2017choosing, dwyer2018machine, mariani2022ai) Different from the article mentioned above in the medical and psychology field, our paper is not only about using algorithms to assist with medical diagnoses; the greater contribution of our article lies in our comparison of algorithmic and physician decision-making, as well as the exploration of their potential complementarity.(NO USE ANYMORE!!!)}}

Optimal decision making using machine learning techniques is also drawing increasing attention from econometrics. kitagawa2018should, mbakop2021model, athey2021policy and feng2024statistical explore the asymptotic properties of empirical algorithm based optimal decision making. manski2018credible considers the identification problem when only the prediction conditional on a subset of covariates and the conditional distribution of the “omitted” covariates are known. In this paper, we assume, as in the baseline cases of kitagawa2018should, that the machine algorithm is known and deterministic, in view of the large data size and the comprehensive list of covariates in the NFPC dataset.

comment\textcolor{cyan}{A large literature exploits the result of cases to judges and other decision-makers to estimate the causal effects in the field of college admissions, bail decisions, psychology, medical science.vytlacil2002independenceproposed conditions for estimation are further relaxed by de2017tolerating, frandsen2023judging who introduced more generalized conditions. A key assumption held in these literature about estimation is monotonicity. angrist1995two provide a methodology for verifying the monotonicity condition in scenarios where interventions adopt on more than two values while chan2022selection demonstrate that the monotonicity condition could be violated if there are systematic skill differences between decision-makers, even under the average monotonicity assumption (frandsen2023judging). In the specific study of radiologists assessing pneumonia, such skill disparities are deemed significant enough to invalidate the assumption of average monotonicity, while our paper’s framework does not rely on this assumption, avoiding the issue.}

The rest of this paper is organized as follows. Section (ref) presents the statistical model of human-algorithm comparison. Section (ref) describes the data and the algorithm. Section (ref) reports results from the empirical analysis of the machine algorithm and human decision makers. Section (ref) presents a set of synthetic data analysis for additional insights, and Section (ref) concludes. Additional results are collected in the Appendix.

Replacing Human Decision Makers with Algorithms

Consider a sample dataset with labels $Y_i \in \{0,1\}$ and features $X_i,i=1,\ldots,n$. Define

align[align omitted — 250 chars of source]

where $\hat Y_i \in \{0, 1\}$ is a predictor for $Y_i$ based on a general decision rule, such that $\(X_i, Y_i, \hat Y_i\right)$ are i.i.d draws from an underlying population. The Law of Large Number implies that the FPR/TPR converge to their population analogs (denoted as $\beta$ and $\alpha$) as $n\rightarrow \infty$:

align[align omitted — 258 chars of source]

A key concept in this paper is incentive heterogeneity. In general terms, incentive refers to the motivation of certain actions, and incentive heterogeneity refers to different payoffs across multiple human decision makers for taking the same actions. Incentive heterogeneity can typically be classified intuitively as either intra-individual or inter-individual. On the one hand, inter-individual incentive heterogeneity refers to situations where the cost assessment only varies across decision makers but not across individual cases for each decision maker. On the other hand, intra-individual incentive heterogeneity refers to situations where the cost assessments across individual cases for a given decision maker vary based on both publicly observed features $x$ that are accessible by the machine algorithm and private information features $u$ that are only available to human decision makers.

commentIn this paper, intra-individual incentive heterogeneities refer to situations where a human decision maker will change the cost assessment based on publicly observed information features $x$ that are accessible by the machine algorithm and private information features $u$ that are exclusively available only to human decision makers.

To compare human decision makers and machines, we make the following two assumptions regarding incentive heterogeneity:

assumptionThe machine ROC curve is generated by a propensity score model of prediction: \begin{align}\begin{split}\nonumber \hat{y}_{i, M} = \mathds{1}\(m\(x_i\right) > c\right). \end{split}\end{align} The decision maker $j$'s decision is also based on a perceived propensity score model: \begin{align}\begin{split}\nonumber \hat{y}_{i,j} = \mathds{1}\(q_{j}\(x_{i,j}, u_{i,j}\right) > c_j\right). \end{split}\end{align} Both $m\left(\cdot\right)$ and $q_{j}\left(\cdot\right)$ can be correctly specified or misspecified.
comment{\color{red}{(I think this assumption is redundant, the Assumption (ref) already states that $m\left(\cdot\right)$ and $p\left(\cdot\right)$ are deterministic and we do not need $q\left(\cdot\right)$ to be known.) \begin{assumption} Both the machine ROC and the perceived propensity score functions $m\left(\cdot\right)$ and $q\left(\cdot\right)$ are precisely known without any sampling error. \end{assumption} }}
comment{\color{blue}{ (If we would like to emphasis that $m\left(\cdot\right)$ and $q\left(\cdot\right)$ to be deterministic and also want to left some flexibility in the Assumption (ref), we can rewrite the second assumption as)}}

Assumption (ref) rules out intra-individual incentive heterogeneity and allows us to focus on inter-individual incentive heterogeneity. Doctors in our dataset exhibit highly variable degrees of conservativeness in their diagnoses. The FPR of the doctors with at least 300 diagnoses has a mean of 0.236 and a standard deviation of 0.230. Some doctors tend to diagnose almost all patients as highly risky, and some doctors rarely make a positive diagnosis. Figure (ref) illustrates. The diffusive distribution of doctors' FPR/TPR pairs also indicates both information processing capacity difference and inter-individual heterogeneity. The analysis in chan2022selection shows that when only either diagnostic skill difference or inter-individual incentive heterogeneity is present, the doctors FPR/TPR paris will concentrate in a small region, which is not the case in Figure (ref). Importantly, Assumption (ref) also allows for private information $u_{i,j}$ that is only observed by the doctors and not used in the machine learning algorithm. In the absence of the private information variable $u_{i,j}$, the doctors' diagnoses are perfectly predictable by the machine learning algorithm, which is very unlikely.

comment\begin{figure} \caption{The distribution of doctors' FPRs (doctors' diagnoses $\geq$ 300)} \end{figure}
assumptionThe machine propensity score model $m\(x_i\right)$ and the $j$th decision maker's propensity score model $q_j\(x_{i,j},u_{i,j}\right)$ are used without sampling errors in the machine decision making procedure and by the $j$th decision maker, respectively.

The first requirement is justified by the fact that the machine learning model is implemented using a training dataset that is by orders of magnitude larger than the number of cases for each individual human decision maker. For instance, around 150 thousand cases in the NFPC training dataset are used to estimate the machine ROC curve, whereas the median number of diagnoses per doctor in the classification set is only approximately 400. The estimation error in the machine ROC curve is negligible relative to the error in estimating doctors' FPR/TPR pairs. The sampling error in estimating the machine ROC curve is studied in a subsequent paper by feng2024statistical.

The second requirement that the $q_j\(x_{i,j},u_{i,j}\right)$ are used without sampling errors by the $j$th decision maker is interpreted as stating that the behavior of the $j$th decision maker is consistent with the use of a propensity score model $q_j\(x_{i,j},u_{i,j}\right)$. The method in this paper does not require the researcher to know the propensity score model $q_j\(x_{i,j},u_{i,j}\right)$ for the $j$th decision maker, and does not refer to any of the doctor propensity score models $q_j\(x_{i,j},u_{i,j}\right), j = 1,\ldots,J$.

commentUnder the second requirement, a doctor $j$ does not update their propensity score model $q_j\(x_{i,j},u_{i,j}\right)$ during the sampling period in the dataset, i.e. it also rules out decision makers learning from the sample cases.

The second requirement also rules out decision makers learning from the sample cases. A doctor $j$ does not update their propensity score model $q_j\(x_{i,j},u_{i,j}\right)$ during the data sample period.

This is a reasonable assumption in our empirical dataset because the eventual pregnancy outcomes are typically not available to doctors when they diagnose consecutive patient cases. We are not concerned with how doctors procure knowledge to develop their diagnosis model $q_j\(x_{i,j},u_{i,j}\right)$. Doctor $j$ might procure $q_j\(x_{i,j},u_{i,j}\right)$ from trainings obtained from a medical school or from working with a large pool of patients prior to the sampling period. Section (ref) provides more details about the data processing procedure, where sampling errors arise mainly from the relatively fewer number of observations for each individual decision maker.

Human FPR/TPR pairs and ROC curves in the population

The parameter of interest is the population pair of true positive and false positive rates for an individual decision maker: $\theta_{H} = \left(\alpha_{H}, \beta_{H}\right)$, where $\alpha$ and $\beta$ are defined as in (ref) and the subscript $H$ refers to “human”. If $\theta_{H}$ is above a machine ROC curve, as in Figure (ref), then given the FPR $\alpha_{H}$, the algorithm has a lower TPR $\beta_{M}$ than humans have. Similarly, given the TPR $\beta_{H}$, the machine has a larger FPR $\alpha_{M}$ than humans have. In this sense, humans outperform the algorithm. In particular, under Assumption (ref), if humans correctly use at least as much information as the algorithm does, in the sense that the propensity model is correctly specified, then $\theta_{H}$ lies above the machine ROC. The formal argument is given in Lemma (ref) in the appendix.

Figure (ref) shows a $\theta_{H}$ pair for a human decision maker that is below the machine ROC curve. A machine decision rule corresponding to a point on the machine ROC curve between A and B performs better than the human decision maker. The segment of the curve to the left of B (to the right of A) has a smaller $\alpha_{M}$ but a smaller $\beta_{M}$ (a larger $\beta_{M}$ but a larger $\alpha_{M}$) than the human decision maker. These segments of the machine ROC curve are not directly comparable to the human decision maker.

figure[figure omitted — 514 chars of source]

The classical Neyman-Pearson lemma states that when $p\(x\right)=\mathbb{P}\(Y=1\vert x\right)$ is correctly specified, for any pair of positive numbers $\left(\eta, \phi\right)$, there exists a cutoff value $c$, such that the point $\left(\alpha_c, \beta_c\right)$ on the ROC curve corresponding to the decision rule $\hat y = \mathds{1}\(p\(x\right)>c\right)$ maximizes a linear combination $\phi\beta - \eta\alpha$ of the TPR and FPR. Conversely, each point on this ROC curve optimizes some linear combination of TPR and FPR. Neyman-Pearson Lemma is also motivated by a Bayesian decision maker who minimizes posterior expected loss of misclassification upon observing the features $x$, based on a loss matrix of the following form:

center[center omitted — 226 chars of source]

where $c_{10}$ represents the cost of misclassifying $1$ as $0$ and $c_{01}$ represents the cost of misclassifying $0$ as $1$. Each point on the ROC curve, corresponding to a decision rule $\hat y = \mathds{1}\(p\(x\right) > c\right)$, minimizes Bayesian posterior expected loss for some choice of $c_{10}$ and $c_{01}$ through the relation $c = \frac{c_{01}}{c_{10} + c_{01}}$. Importantly, the cost matrix $c_{01}, c_{10}$ and linear combination coefficients $\eta, \phi$ in the Neyman-Pearson Lemma are independent of the features $x$ in order to provide optimality justification of the points on the ROC curve. Assumption (ref) is then interpreted as each doctor behaving as a Bayesian decision maker adopting the same constant cost matrix $c_{10}$ and $c_{01}$ among their patients. The ex ante expected minimized cost for the Bayesian decision maker corresponds to a linear combination of FPR and TPR:

align[align omitted — 241 chars of source]

If we denote point A and B in Figure (ref) as $\left(\alpha_{H}, \beta_{R}\right)$ and $\left(\alpha_{R}, \beta_{H}\right)$, then any point $\left(\alpha_{M}, \beta_{M}\right)$ between $\left(\alpha_{R}, \beta_{H}\right)$ and $\left(\alpha_{H}, \beta_{R}\right)$ on the machine ROC curve satisfies $\alpha_{M} < \alpha_{H}$ and $\beta_{M} > \beta_{H}$. For arbitrary $\phi, \eta > 0$ and $c_{10}, c_{01}$,

align[align omitted — 245 chars of source]

Therefore, compared with human decisions, any point $\left(\alpha_{M}, \beta_{M}\right)$ between $\left(\alpha_{R}, \beta_{H}\right)$ and $\left(\alpha_{H}, \beta_{R}\right)$ on the ROC curve achieves a better linear combination for all possible values of $\phi, \eta$, and lower expected cost for all loss matrixes of $c_{01}, c_{10}$. In this sense, $\left(\alpha_{M}, \beta_{M}\right)$ dominates $\left(\alpha_{H}, \beta_{H}\right)$.

Recall that $\theta_{H}$ is a population parameter that measures the expected performance of the human decision maker. When $\theta_H$ lies below the machine ROC curve, {\it on average}, the machine algorithm can outperform the human decision maker by increasing the population TPR or reducing the population FPR. However, unless the algorithm can make predictions with perfect accuracy, for each specific patient case, the human decision maker can either underperform or outperform the algorithm.

commentIn order to provide a more precise interpretation of the sense in which the machine algorithm performs better than the human decision maker when $\theta_H$ lies below the machine ROC curve, recall that $\theta_{H}$ is a population parameter that measures the average performance of the human decision maker after the decision maker sees an infinite number of cases. Therefore, {\it on average}, given $\alpha_{H}$ or $\beta_{H}$, the machine algorithm can outperform the human decision maker by increasing the population TPR or reducing the population FPR, respectively. However, unless the algorithm can make predictions with perfect accuracy, for each specific patient case, the human decision maker can either underperform or outperform the algorithm.

Our framework is likely to be applicable when people make many repeated decisions to allow for a sufficiently precise estimate of their error rates. It is less applicable in situations when people only ever make a few decisions of a type, a setting that may arise even when decisions are frequent if some action rarely is or should be taken. The lack of information renders the task of distinguishing humans from algorithms difficult, even if humans might be detectably worse in aggregate\footnote{We are grateful to the associate editor for pointing out this important clarification.}. Our application features a comprehensive set of covariates, a large dataset, reliable and measurable outcomes, and a stable prediction environment that are consistent with the scenarios in the important papers by kahneman2009conditions and currie3.

commentIn light of the previous interpretation, our framework is likely to be applicable when people make many repeated decisions to allow for a sufficiently precise estimate of their error rates, but is less applicable in situations when people only ever make a few decisions of a type. Such settings may arise even when decisions are frequent if some action rarely is or should be taken. The lack of information renders the task of distinguishing humans from algorithms difficult, even if humans might be detectably worse in aggregate\footnote{We are grateful to the associate editor for pointing out this important clarification.}. Our application features a comprehensive set of labels, a large dataset, reliable and measurable outcomes, and a stable prediction environment that is consistent with the scenarios in the important papers by kahneman2009conditions and currie3.

Human FPR/TPR pair and ROC curve comparison in the sample

Typically, the population value of $\theta_{H}$ is not directly observed, and instead needs to be estimated from a dataset. Denote the the sample estimates $\left(\text{FPR}, \text{TPR}\right)$ in (ref) as $\hat{\theta}_{H} = \left(\hat{\alpha}_{H}, \hat{\beta}_{H}\right)$. In the presence of sampling uncertainty, the inference problem pertains to how we can make a probabilistic statement regarding whether $\theta_{H}$ is above or below the machine ROC curve. From a frequentist analysis point of view, because the sample estimate $\hat{\theta}_{H}$ is a vector function of a multinomial distribution, the finite sample distribution function of $\hat{\theta}_{H}$ can be analytically intractable. Large sample frequentist analysis and simulation methods, however, are facilitated by the joint asymptotic normal distribution of $\hat{\theta}_{H}$.

lemmaFor an i.i.d. sample $\left\{Y_{i}, \widehat{Y}_{i}\right\}^{n}_{i}$, the joint asymptotic distribution of a human FPR/TPR pair $\hat{\theta}_{H} = \left(\hat{\alpha}_{H}, \hat{\beta}_{H}\right)$ is multivariate normal. In particular \begin{align}\begin{split}\nonumber \sqrt{n}\left(\hat{\theta}_{H} - \theta_{H}\right) \overset{d}{\longrightarrow} N\left(0, \Sigma\right), \quad \Sigma = \left( \begin{array}{cc} \frac{\alpha_{H}\left(1 - \alpha_{H}\right)}{1 - p} & 0\\ 0 & \frac{\beta_{H}\left(1 - \beta_{H}\right)}{p} \end{array}\right). \end{split}\end{align}

The proof of Lemma (ref) is given in the appendix and follows from standard arguments for approximating multinomial distributions with normal limits. The asymptotic covariance $\Sigma$ can be consistently estimated by a sample analog $\hat\Sigma$ where the parameters $\alpha_H, \beta_H$ and $p$ are replaced by $\hat{\alpha}_H, \hat{\beta}_H$ and $\hat{p}$. The resulting asymptotic confidence set of the FPR/TPR pairs is elliptically shaped. As illustrated in Figure (ref), the blue ellipse indicates a 95% level confidence set for a decision maker in our dataset.

comment\begin{figure} \caption{Case 1 of the heuristic approach for a human decision maker: when the confidence set is dominated by points on the machine ROC curve} \end{figure}
figure[figure omitted — 1,224 chars of source]

An immediate consequence of Lemma (ref) is that a direct comparison of the sample estimate $\left(\hat\alpha_H,\hat\beta_H\right)$ with the machine ROC curve is likely to be insufficient. Consider a situation where the true population pair of $\left(\alpha_H, \beta_H\right)$ lies strictly below the machine ROC curve: $\beta_H < g\left(\alpha_H\right)$ where $g\left(\cdot\right)$ denotes the machine ROC curve. Then with probability converging to $1$, $\left(\hat\alpha_H, \hat\beta_H\right)$ lies strictly below the machine ROC. Suppose we replace $\left(\hat\alpha_H, \hat\beta_H\right)$ by $\left(\hat\alpha_H, g\left(\hat\alpha_H\right)\right)$. By Lemma (ref), $\mathbb{P}\left(\hat\alpha_H \geq \alpha_H\right)\rightarrow 0.5$. In other words, the replacement point $\left(\hat\alpha_H, g\left(\hat\alpha_H\right)\right)$ on the ROC curve does not dominate the true population pair of $\left(\alpha_H, \beta_H\right)$ approximately half of the time. A similar situation arises if we replace $\left(\hat\alpha_H, \hat\beta_H\right)$ by $\(g^{-1}\left(\hat\beta_H\right), \hat{\beta}_{H}\right)$.

commentSimilarly, if we replace $\left(\hat\alpha_H, \hat\beta_H\right)$ by $\(g^{-1}\left(\hat\beta_H\right), \hat{\beta}_{H}\right)$, Then by Lemma (ref), $\mathbb{P}\left(\hat\beta_H \leq \beta_H\right)\rightarrow 0.5$. It is also the case that the replacement point on the ROC curve $\(g^{-1}\left(\hat\beta_H\right), g\left(\hat\alpha_H\right)\right)$ does not dominate the true population $\left(\alpha_H, \beta_H\right)$ approximately half of the time.

In order to provide a probabilistic statement regarding the property of the replacement procedure, a more formal statistical framework is necessary. We consider both a heuristic frequentist approach and a Bayesian approach.

commentFor conventional levels of $\alpha$, we typically do not reject a decision when $\hat t \geq 0$. More generally, a typical test rejects a decision when $\hat t \geq \hat c_{1-\alpha}$, for a suitable chosen $\hat c_{1-\alpha}$ such that \begin{align}\begin{split}\nonumber \mathbb{P}\left( \hat t \geq \hat c_{1-\alpha} \vert t_0 = 0 \right) \rightarrow \alpha. \end{split}\end{align} The Delta method sets $\hat c_{1-\alpha} = \sqrt{ \frac{\hat B \hat\Omega \hat B'}{n} } z_{1-\alpha}$. The popular bootstrapping provides an alternative implementations of $\hat c_{1-\alpha}$, set $\hat c_{1-\alpha}$ to the $1-\alpha$ percentile of the empirical distribution of $\tilde{t}_b - \hat t, b=1,\ldots,B$, where $\hat t_b$'s are bootstrapped replications of $\hat t$.
comment{\color{purple}{There are several choices for $\hat c_\alpha$. The first choice is the analytic Delta method, where $\hat c_\alpha = z_\alpha \sqrt{\hat B \hat\Sigma\hat B'/ n}$. The second choice is the asymptotic Delta method: for large $R$, draw for $r=1,\ldots,R$, $\omega_r$ from $N\left(0, \hat\Sigma/n\right)$. Set $\hat c_{\alpha}$ to the $\alpha$ percentile of the empirical distribution of $\hat\theta_2 + \omega_{2r} - g\left(\hat\theta_1 + \omega_{1r}\right) - \left(\hat\theta_2- g\left(\hat\theta_1\right)\right)$. The third option is bootstrapping. Set $\hat c_{\alpha}$ to the $\alpha$ percentile of the empirical distribution of $\hat t_b - \hat t, b=1,\ldots,B$, where $\hat t_b$'s are bootstrapped replications of $\hat t$.}}
commentUsing conventional confidence sets to construct tests of $H_0$ against $H_1$ in (ref) will likely generate issues. Recall that a conventional confidence set is given asymptotically by \begin{align}\begin{split}\nonumber \left\{\theta: n \left(\theta-\hat{\theta}_{H}\right)'\hat\Sigma^{-1} \left(\theta-\hat{\theta}_{H}\right) \leq \chi^2_{2,1-\alpha}\right\}, \end{split}\end{align} Consider the following alternatives. \begin{itemize} • Test 1 (T1): Reject a decision if $\hat{\beta}_{H} > g\left(\hat{\alpha}_{H}\right)$ and $\left(\hat{\alpha}_{H}, g\left(\hat{\alpha}_{H}\right)\right)$ is below the confidence set. • Test 2 (T2): Reject a decision if the entire confidence set lies above the ROC. • Test 3 (T3): Reject a decision if a point on the ROC is simultaneously dominated by all points on the confidence set. \end{itemize} T1 rejects a decision if $\hat{\beta}_{H} > g\left(\hat{\alpha}_{H}\right)$ and $n \left[\hat{\Sigma}^{-1}\right]_{2,2} \left(\hat{\beta}_{H} - g\left(\hat{\alpha}_{H}\right)\right)^2 \geq \chi^2_{2,1-\alpha}$. Note that $\left[\hat{\Sigma}^{-1}\right]_{2,2} \overset{\mathbb{P}}{\longrightarrow} \sigma^{-1}_{22}$. However, under the least favorable null: \begin{align}\begin{split}\nonumber \hat{\beta}_{H} - g\left(\hat{\alpha}_{H}\right) \approx \hat{\beta}_{H} - \beta_{H} - G_{H}\left(\hat{\alpha}_{H} - \alpha_{H}\right) \sim N\left(0, \sigma_{22} + G_{H}^2 \sigma_{11}\right). \end{split}\end{align} The test statistic distribution is not $\chi_2^2$ and is unlikely to have the correct size. T2 rejects a decision if $\hat\theta_2 > g\left(\hat\theta_1\right)$ and if $\inf_{x: x_2 = g\(x_1\right)} n \(x - \hat\theta\right)' \hat\Omega\(x - \hat\theta\right) \geq \chi^2_{2, 1-\alpha}.$ The left-hand side is the J-statistic for one overidentifying restriction and has an asymptotic $\chi_1^2$ distribution (not $\chi_2^2$). Since $\chi^2_{2,1-\alpha} \geq \chi^2_{1,1-\alpha}$, the null rejection probability is less than $\alpha$. Therefore, this test is conservatively valid (undersized) and is likely to be less powerful. This result is in addition to the power loss from essentially using a two-sided test for a one-sided hypothesis. T3 is obviously even more conservative than T2. Therefore, T3 will be undersized and less powerful. The same issues also concern mirror versions of T1 to T3 for testing (ref).

A heuristic frequentist approach

We initially experiment with a heuristic procedure based on the frequentist principle, the predominant school of thought in statistical inference which typically begins with confidence set construction. The procedure is described as follows.

itemize• Form a confidence set $\hat S$ for $\theta_{H}$. By Lemma (ref), $n\left(\hat{\theta}_{H} - \theta_{H}\right)^{T}\hat{\Sigma}^{-1}\left(\hat{\theta}_{H} - \theta_{H}\right)$ converges to a Chi-square distribution with two degrees of freedom, where $\hat{\Sigma}$ is any consistent estimator of $\Sigma$. A confidence set on this asymptotic distribution is elliptically shaped. • For each $s=\left(\alpha_s, \beta_s\right) \in \hat S$, define $A_s$ as the set of points that {\it dominate} $s$: \begin{align}\begin{split} A_s = \left\{\theta = \left(\alpha, \beta\right): \alpha \leq \alpha_s, \beta \geq \beta_s\right\}. \end{split}\end{align} • Define $A = \bigcap_{s \in \hat{S}} A_s$: $A$ is the set of points that dominate all the points in $\hat S$. • Next, define $\bar A = A \cap \text{ROC}$: $\bar A$ is the set of points on the machine ROC curve that simultaneously dominate all the points in $\hat S$.

The convention of choosing a large confidence level suggests that the status quo of human decision making is to be replaced by an algorithm only when there is overwhelming evidence from the data indicating the superiority of the algorithm. In our application, we will only consider the machine algorithm to outperform the human decision when $\bar A \neq \emptyset$, i.e., when there exists a point on the machine ROC curve that dominates an entire confidence set of the human decision maker's $\theta_{H}$ parameter. In essence, we use estimates of the sampling uncertainty of the FPR/TPR pair of $\hat\theta_H$ to provide guidance on how far $\hat\theta_H$ needs to be below the machine ROC curve in order to justify replacing the human decision maker with the machine algorithm.

In the elliptical confidence set depicted in Figure (ref), denote by $\left(\alpha_{\beta_{high}}, \beta_{high}\right)$ the point that achieves the highest TPR on the confidence set, and denote by $\left(\alpha_{low}, \beta_{\alpha_{low}}\right)$ the point that achieves the smallest FPR on the confidence set. The point $\text{P}$ in Figure (ref) corresponds to $\left(\alpha_{low}, \beta_{high}\right)$. There are three possibilities for the relation between the position of the confidence set for the human FPR/TPR pair $\theta_H$ and the machine ROC curve.

enumerate• Case 1 (Figure (ref)): The human confidence set and point $P=\left(\alpha_{low}, \beta_{high}\right)$ are both below the machine ROC curve. We consider the human decision maker to perform “worse” than the algorithm and hence can be replaced by the algorithm. On the machine ROC curve, we can find two points, namely, $\left(\alpha_{R}, \beta_{high}\right)$ and $\left(\alpha_{low}, \beta_{R}\right)$, labeled as points B and A in Figure (ref), such that any point on the ROC curve between A and B can provide a machine decision rule to replace human decision making. • Case 2 (Figure (ref)): The entire human confidence set is below the ROC curve, but the point $P=\left(\alpha_{low}, \beta_{high}\right)$ is above the ROC curve. In this case, even though each point in the confidence region of $\theta_{H}$ is dominated by some point on the machine ROC curve, it is not possible to find a nonempty fraction of the machine ROC curve that simultaneously dominates all the points in the human confidence set. The data evidence is not sufficiently convincing to account for the randomness of estimating $\theta_H$ by $\hat{\theta}_{H}$. Consequently, the human decision maker is not replaced by the algorithm. • Case 3 (Figure (ref)): The human confidence set has a certain area above the machine ROC curve. The human decision maker is not replaced by the algorithm either.

In summary, if the point $P=\left(\alpha_{low}, \beta_{high}\right)$ is below the ROC curve, the human decision maker is replaced; otherwise, they are not. In cases 2 and 3, it is possible that the human decision maker is sufficiently capable compared to the machine algorithm. It is also possible that the human $\theta_{H}$ is not estimated precisely enough, for example, due to a lack of historical data that results in a large confidence set.

comment\begin{figure} \subfigure[Case 2 of the heuristic approach for a human decision maker] \subfigure[Case 3 of the heuristic approach for a human decision maker] \caption{Two cases of the heuristic approach: where the confidence sets are not dominated by any point on the machine ROC Curve} \end{figure}

In frequentist statistical inference, $\theta_{H}$ is a fixed number. It is either above or below the machine ROC curve. The confidence set itself $\hat S$ is a random set, such that $\mathbb{P}\left(\theta_H \in \hat S\right) \longrightarrow 1 - \alpha.$ For a conventional size of $\alpha = 0.05$, if the confidence set is to be constructed 100 times from different samples, $\hat S$ will contain $\theta_{H}$ approximately 95 times. Consequently, by construction, $\bar A$ is a random set such that asymptotically,

align[align omitted — 283 chars of source]

Therefore, we have asymptotically

align[align omitted — 295 chars of source]

If $\theta_{H}$ lies below the ROC curve, $\mathbb{P}\left\{\bar{A} = \emptyset\right\} \to 0$ as the number of cases for the human decision maker increases to infinity. Furthermore, $\mathbb{P}\left\{ \bar{A} = \emptyset \text{ and P dominates } \theta_{H}\right\} < \mathbb{P}\left\{\bar{A} = \emptyset\right\} \rightarrow 0$, implying that asymptotically, $\mathbb{P}\left\{\bar{A} \text{ dominates } \theta_{H} \vert \bar{A} \neq \emptyset\right\} \geq 1 - \alpha.$ If $\theta_H$ lies above the ROC, we can control $\mathbb{P}\left\{\bar A = \emptyset\right\} \geq 1-\alpha$ by reasoning that

align[align omitted — 262 chars of source]

However, the finite sample size of the test can be severely distorted. By insisting on finding a segment of the machine ROC curve that simultaneously dominates the entire confidence region of $\theta_H$, the frequentist procedure is conservative by construction.

While conventional confidence sets are mostly symmetric, it is well known in statistics that by inverting a hypothesis test, alternative confidence sets can be constructed as the collection of parameter values for which the null hypothesis is not rejected. For example, if we let the null hypothesis be $H_0: \theta_H = \theta_{0H}$ and the alternative hypothesis be $H_1: \alpha_H > \alpha_{0H}\ \text{or}\ \beta_H < \beta_{0H}$, a test can be formed to reject the null hypothesis $H_0$ when either $\hat\alpha_H > \alpha_H + c$ or when $\hat\beta_H < \beta_H - d$, where $c$ and $d$ are chosen by the size of the test. The confidence set of $\theta_{0H}$ where the test does not reject takes the form of $\{\theta_{0H}: \alpha_{0H} \geq \hat\alpha_H -c,\ \text{and}\ \beta_{0H} \leq \hat\beta_H +d\}$, which is lower rectangular. While forming confidence sets based on inverting inequality tests is theoretically intriguing, it is not often used empirically.

An alternative in Appendix (ref) is to test whether the population value of $\theta_H$ is above or below the machine ROC curve.

commentThe status quo of human decision making is typically chosen as the null hypothesis of $H_0: \theta_{H} \ \text{lies above ROC}$. This implies that a priori, we maintain confidence in human decision making unless overwhelming evidence suggests otherwise. As the machine ROC curve is represented by $\beta = g\left(\alpha\right)$, we can rewrite the null and alternative hypotheses as \begin{align}\begin{split}\nonumber H_0: \beta_{H} \geq g\left(\alpha_{H}\right) \quadagainst\quad H_1: \beta_{H} < g\left(\alpha_{H}\right). \end{split}\end{align} Under the least favorable null hypothesis, the asymptotic distribution of a test statistic $\hat t = \hat\beta_{H} - g\left(\hat\alpha_{H}\right)$ follows from combining Lemma (ref) with the Delta method. More precisely, if we define $\hat B = \left(-g'\left(\hat\alpha_H\right), 1\right)$, then the following central limit theorem holds under the least favorable null hypothesis: \begin{align}\begin{split}\nonumber \mathbb{P}\left( \frac{ \sqrt{n}\left(\hat\beta_H - g\left(\hat\alpha_H\right)\right) }{ \sqrt{ \hat B \hat\Sigma \hat B' } } \leq \Phi^{-1}\left(\alpha\right) \right)\rightarrow \alpha. \end{split}\end{align} In the above, we use $\Phi^{-1}\left(\alpha\right)$ to denote the $\alpha$-th percentile of the standard normal distribution. A test that rejects the null hypothesis when $\frac{ \sqrt{n}\left(\hat\beta_H - g\left(\hat\alpha_H\right)\right) }{ \sqrt{ \hat B \hat\Sigma \hat B' } }$ is less than $\Phi^{-1}\left(\alpha\right)$ will have asymptotic size $\alpha$.

We do not use this test because of its limitation that even if the null hypothesis of the status quo of human decision making is rejected, it does not locate a point of the machine ROC curve to replace human decisions, as discussed in section (ref).

A Bayesian approach

In the following we focus on an alternative Bayesian method, which often allows for a more transparent interpretation than frequentist inference. The Bayesian approach combines a prior distribution of the underlying population parameters with the likelihood of the data given the population parameters to produce a posterior distribution of the parameters given the data, which is then used in a decision theoretic framework where a threshold is chosen to minimize the posterior expected loss function. The combination of a multinomial likelihood function with a Dirichlet conjugate prior drastically improves computability. Simulating the posterior distribution of the key FPR/TPR parameters to construct a Bayesian credible set is facilitated by writing them as a vector function of the multinomial parameters whose posterior distribution is given analytically through the conjugate prior.

commentA Bayesian credible set is then constructed to replace approximate frequentist confidence regions based on the asymptotic normal distribution.

The empirical results suggest that the Bayesian method is less conservative and suggests replacement of more doctors by the machine algorithm than the frequentist method does.

Computing a Bayesian posterior distribution requires two key inputs: the likelihood of the data given the population value of $\theta_{H}$, and a prior distribution for the underlying population parameters. Each observation in the dataset consists of both the doctor diagnoses and the ground truth of pregnancy outcomes, and follows a multinomial distribution with four categories: diagnosed as risky and abnormal birth outcome; not diagnosed as risky and abnormal birth outcome; diagnosed as risky and normal birth outcome; not diagnosed as risky and normal birth outcome. The parameters of the multinomial probabilities are:

align[align omitted — 252 chars of source]

Since $t_1 + t_2 + t_3 + t_4 = 1$, we choose the first three as free parameters. The multinomial distribution is a completely specified parametric model and allows for exact likelihood Bayesian posterior distribution computation. The likelihood of the data given the free parameters $t=\(t_1, t_2, t_3\right)$ depends only on a set of sufficient statistics $\hat t=\left(\hat t_1, \hat t_2, \hat t_3\right)$ where

align[align omitted — 265 chars of source]

In particular, we can write the data likelihood as (where $\mathbb{D}$ refers to Data):

align[align omitted — 287 chars of source]

Given a prior distribution of $t$, denoted as $\pi\(t\right)$, the posterior distribution of the parameter $t$, denoted as $p\(t \vert \mathbb{D}\right)$ can usually be simulated or calculated analytically:

align[align omitted — 202 chars of source]

We are interested in the posterior distribution of $\theta_H=\left(\alpha_H, \beta_H\right)$, which can be written as functions of the underlying multinomial parameters: $h\(t\right) = \left(\alpha_{H}\(t\right), \beta_{H}\(t\right)\right)$. If we can simulate from the posterior distribution $p\(t \vert \mathbb{D}\right)$ and denote the simulated draws as $t_r, r=1,\ldots,R$, then the posterior distribution of $\theta_{H}$, denoted as $p\left(\theta_H \vert \mathbb{D}\right)$, can be estimated using the empirical distribution of $h\(t_r\right), r=1,\ldots,R$.

Computing the posterior distribution using a multinomial likelihood is facilitated by the Dirichlet conjugate prior. A Dirichlet prior on the K-dimensional simplex of $t_k,k=1,\ldots,K$, where $\sum_{k=1}^K t_k=1$, is specified by hyper-parameters $\gamma=\left(\gamma_k,k=1,\ldots,K\right)$. Its density is given by $\pi\(t\vert \gamma\right)=\frac{1}{B\left(\gamma\right)} \prod_{k=1}^K t_k^{\gamma_k-1}$, where $B\left(\gamma\right)$ is the multivariate Beta function. See for example kotz2019continuous. The case with $\gamma_k=\gamma, \forall k=1,\ldots,K$ is called a symmetric Dirichlet distribution. In one dimension, where $K=1$, the Dirichlet distribution specializes to a Beta distribution, which in turn includes the uniform distribution as a special case when $\gamma=1$.

The posterior distribution is also Dirichlet with parameters $\hat\gamma=\left(\hat\gamma_k,k=1,\ldots,K\right)$, where $\hat{\gamma}_k = \gamma_k + n \hat t_k$ for each $k=1,\ldots,K.$ Simulating from the posterior distribution of $\theta_{H} = \left(\alpha_{H}, \beta_{H}\right)$ can be accomplished by recomputing $\theta_{H,r} = h\(t_r\right)$ after drawing for $t_r$ from the posterior Dirichlet distribution with parameters $\hat\gamma$. Specifically, for each $t_r = \(t_{r,k}\right)^{K}_{k = 1}$, we calculate

align[align omitted — 292 chars of source]

The simulated draws $\theta_{H,r}, r=1,\ldots,R$ can be used to estimate posterior probabilities. For example, the posterior probability that $\theta_{H}$ lies below the ROC curve, denoted as

align[align omitted — 165 chars of source]

can be estimated by the fraction of times where $\theta_{H, r}$ lies below the ROC curve:

align[align omitted — 254 chars of source]

We are mainly interested in the {\it maximum} posterior probability of $\theta_{H}$ that are dominated simultaneously by a single point on the ROC curve, denoted as

align[align omitted — 256 chars of source]

and the corresponding maximizing point, denoted as $\theta_{max} = \left(\alpha_{max}, \beta_{max}=g\left(\alpha_{max}\right)\right)$, where

align[align omitted — 273 chars of source]

Both (ref) and (ref) can be estimated by the simulated posterior draws of $\theta_{H, r}, r = 1, \ldots, R$, by

align[align omitted — 444 chars of source]

More generally, decision-theoretic Bayesian analysis minimizes posterior expected losses. Let $\rho\left(\theta_{M}, \theta_{H}\right)$ denote a loss function that represents the disutility of replacing a human FPR/TPR pair $\theta_H$ by a machine FPR/TPR pair $\theta_M$. Consistent with Assumptions (ref) and (ref), we specify $\rho\left(\theta_{M}, \theta_{H}\right) = 0$ when $\alpha_{M} \leq \alpha_{H}$ and $\beta_{M} \geq \beta_{H}$, or when the machine FPR/TPR pair strictly dominates the human FPR/TPR pair. Otherwise, $\rho\left(\theta_{M}, \theta_{H}\right)$ may be strictly positive. Given the choice of $\rho\left(\theta_M, \theta_H\right)$, a point on the ROC curve can be chosen to minimize the posterior expected loss

align[align omitted — 247 chars of source]

which is also estimated using the simulated posterior draws of $\theta_{H,r}, r=1,\ldots,R$ as

align[align omitted — 182 chars of source]

In particular, (ref) is a special case of (ref) when $\rho\left(\theta_M, \theta_{H}\right) = 1 - \mathds{1}\left(\alpha_{H} \geq \alpha_{M}, \beta_{H} \leq \beta_{M}\right)$. It is also possible to explore more general loss functions. For example, we may weight the loss of replacing $\theta_H$ by $\theta_M$ by the distance between $\theta_H$ and the machine ROC curve:

align[align omitted — 285 chars of source]

where $\Vert\cdot\Vert$ is the Euclidean norm. Intuitively, the farther a human FPR/TPR pair $\theta_H$ is from the ROC curve, the smaller the loss (or the larger the benefit) of replacing it with a dominating point on the machine ROC curve. Alternatively, we can replace the distance from $\theta_H$ to the ROC curve by the distance of each $\theta_M$ to the complement of the set of FPR/TPR points that dominate $\theta_H$, and use the loss function:

align[align omitted — 274 chars of source]

The Euclidean distance from the machine ROC curve may also not fully capture the loss of not replacing a human FPR/TPR pair $\theta_H$ that lies under the machine ROC curve. For example, a diagonal ROC curve corresponds to completely randomized decision making without using feature information. Similarly, a ROC curve below the diagonal can be generated by a decision rule that awards rather than penalizes mis-classification errors. These considerations suggest that replacing a human FPR/TPR pair $\theta_H$ below the diagonal line with a dominating $\theta_M$ along the machine ROC curve should not entail losses. We can adopt a convention of normalizing the loss to be $1$ when $\theta_M$ does not dominate $\theta_H$, i.e., when $\alpha_M \geq \alpha_H$ or $\beta_M \leq \beta_H$.

commentTaking these considerations into account, the loss of replacing a human FPR/TPR pair $\theta_H$ below the diagonal line with a dominating $\theta_M$ along the machine ROC curve can be specified to zero, or an a priori chosen negative number. We can also adopt a convention of normalizing the loss to be $1$ when $\theta_M$ does not dominate $\theta_H$, i.e., when $\alpha_M \geq \alpha_H$ or $\beta_M \leq \beta_H$.

We then specify the loss $\rho\left(\theta_M, \theta_H\right)$ when $\theta_M$ dominates $\theta_H$ and when $\theta_{H}$ lies between the machine ROC curve and the diagonal line. Each of such $\theta_H$ can be reproduced by a convex combination of a point on the machine ROC curve and a point on the diagonal line, using a decision rule that randomizes between the point on the machine ROC curve and the point on the diagonal. For example, $\left(\alpha_H, g\left(\alpha_H\right)\right)$ is generated by a machine based decision rule $\hat Y_{i} = \mathds{1}\(m\(X_{i}\right) > c_0\right)$ for some threshold $c_0$, while $\left(\alpha_H, \alpha_H\right)$ is generated by a fully randomized decision $\hat Y_{i} = \mathds{1}\(U_{i} \geq 1-\alpha_H\right)$ where $U_{i}$ is independently uniformly distributed on $\left(0,1\right)$. Then $\left(\alpha_H, \beta_H\right)$ can be generated by a lottery that places weight $\left(\beta_H-\alpha_H\right)/\(g\left(\alpha_H\right)-\alpha_H\right)$ on $\hat Y_{i} = \mathds{1}\(m\(X_{i}\right) > c_0\right)$ and the remaining weight on $\hat Y_{i} = \mathds{1}\(U_{i} \geq 1-\alpha_H\right)$. More precisely, if $V_{i}$ denotes an independent random variable uniformly distributed on $\left(0,1\right)$, the decision rule

align[align omitted — 342 chars of source]

generates the $\left(\alpha_H, \beta_H\right)$ FPR/TPR pair. The larger the weight $\lambda_{\theta_{H}} \equiv \frac{\beta_{H} - \alpha_{H}} {g\left(\alpha_{H}\right) - \alpha_{H}}$ placed on the machine ROC curve, the smaller the benefit, or the larger the loss, of replacing $\theta_H$ with a dominating pair $\theta_M$ on the machine ROC curve. The randomization scheme motivates using the weight $\lambda_{\theta_{H}}$ as a component of the loss function

align[align omitted — 254 chars of source]

Other randomization schemes can also be used. We refer to the above construction as a vertical decomposition. Similarly, a horizontal decomposition replaces the weights by $\lambda_{\theta_{H}} \equiv \frac{\beta_{H} - \alpha_{H}}{\beta_H - g^{-1}\left(\beta_{H}\right)}$. In addition, we experiment with decomposing the distance between $\theta_M=\left(\alpha_M, \beta_M\right)$ and the diagonal line into two parts. The first part is the distance from $\theta_M$ to the boundary of the set of FPR/TPR points that do not dominate $\theta_H$. The second part is the distance from this boundary to the diagonal line. The corresponding loss function that mirrors is

align[align omitted — 278 chars of source]

where distance can be measured either horizontally, implying that $\lambda_{\theta_{H},\theta_M}=\frac{\beta_M-\alpha_H}{\beta_M-\alpha_M}$, or vertically, implying that $\lambda_{\theta_{H},\theta_M}=\frac{\beta_H-\alpha_M}{\beta_M-\alpha_M}$.

When $\alpha_M < \alpha_H$ and $\beta_M > \beta_H$, replacing $\theta_H$ by $\theta_M$ is beneficial. The benefit, $b\left(\theta_M, \theta_H\right)$, is likely to be larger when $\theta_H$ is farther below the machine ROC curve. When either $\alpha_M > \alpha_H$ or $\beta_M < \beta_H$, we expect a cost $\ell\left(\theta_M, \theta_H\right)$. A general loss function consists of both a cost component and a benefit component:

align[align omitted — 347 chars of source]

For each loss function, a guardrail threshold is used to account for the status quo of human decision making. A human decision maker is only replaced by the machine algorithm when the posterior expected loss of the replacement is below a given prespecified level, or when the posterior expected benefit exceeds a certain level.

In addition to the deterministic decision rules of relying exclusively on either an individual doctor or the machine algorithm, randomized decision rules can be generated by mixing between a given point on the machine ROC curve and an individual doctor. Let $\omega$ denote the randomizing probability of using the machine algorithm, and $1-\omega$ the corresponding probability of relying on the human decision makers. The minimized expected posterior loss of the randomized decision rule can be written as

align[align omitted — 303 chars of source]

Without expert domain knowledge of medical diagnoses, it is difficult to implement (ref) and (ref). Investigating expert domain knowledge is beyond the scope of the current paper.

Our decision framework differs conceptually from the minimization of posterior expected loss function in Bayesian point estimation. A Bayesian point estimator of $\theta_H$, denoted as $\hat\theta_{H,B}$, is often defined as the minimizer of an expected posterior loss function:

align[align omitted — 205 chars of source]

The estimation loss function $\ell\left(\theta - \theta_H\right)$ typically depends only on $\vert\theta-\theta_H\vert$ and is increasing in $\vert \theta-\theta_H\vert$, which is different from our decision loss function $\rho\left(\theta_M, \theta_H\right)$.

Discussion: incentives and costs

The visual illusion shown in Figure (ref) that hampers the comparison between machine learning algorithms and human decision makers is an immediate artifact of Jensen's inequality. An optimal ROC generated by a correctly specified propensity score function is necessarily concave, since it is the primal function of a concave program. See for example feng2022properties. For the $j$th doctor, denote the FPR as $\alpha_j=\mathbb E \left(1-Y_{ij}\right)\hat Y_{ij}/\left(1 - p_j\right)$ and the TPR as $\beta_j=\mathbb E Y_{ij} \hat Y_{ij} / p_j$, where $p_j = \mathbb P\(Y_j =1\right)$. If all the $\left(\alpha_j, \beta_j\right)$ pairs lie on a strictly concave ROC curve $g\left(\cdot\right)$, these variables are related by $\beta_j = g\left(\alpha_j\right)$. When the patient cases across doctors are drawn from the same population, $p_j=p$ is a constant. It follows from Jensen's inequality that

align[align omitted — 208 chars of source]

when $\alpha_{j}$ are not all equal. This important observation appears to have gone largely unnoticed by the literature. Similarly, if each patient $i$ is diagnosed using a point on the human ROC curve $\left(\alpha_{i,j}, \beta_{i,j}\right)$ and if $\alpha_{i,j}, i=1,\ldots,n_j$, are not all equal, it is also the case that

align[align omitted — 246 chars of source]

Lemma (ref) in the supplementary appendix provides a set of primitive conditions under which the aggregate human decision maker FPR/TPR lies strictly below the machine ROC curve.

comment{\color{red}{A machine's binary classification rule is typically based on $D = \mathds{1}(p(x) > c)$, where $x$ is a set of features, the propensity score function $p\(x\right)$ is learned from many data, and $c$ is a cutoff threshold.}} {\color{blue}{Typically, an algorithm first learns a predicative propensity score function $p\(x\right)$ from data, then applies decision rule $\mathds{1}\(p\(x\right) > c\right)$.}} The entire ROC curve will be generated across various cutoff thresholds $c$. Additionally, using historical data, we can {\color{blue}{also calculate}} {\color{red}{compute}} the fix {\color{blue}{sample}} FPR/TPR pairs for individual decision makers.
commentWe do not observe the latent human ROC curve corresponding to $p\(x,u\right)$. By itself, an aggregate human decision maker FPR/TPR pair that lies below a machine ROC curve does not differentiate between a model of incentive heterogeneity, as depicted in Figure (ref), where humans are better informed than machines, and a model of inferior human information processing capacity without incentive heterogeneity, where the human ROC curve corresponding to a misspecified $p\(x,u\right)$ lies below the machine ROC and contains the aggregate FPR/TPR pair.

In general, without the restrictions in Assumptions (ref) and (ref), the decision maker $j$ may use a model $\hat y = \mathds{1}\(q_{j}\(x,u\right) > c_{j}\(x,u\right)\right)$. For decision maker $j$ minimizing expected loss of misclassification conditional on the feature $x$ and $u$, consider the following loss matrix:

center[center omitted — 251 chars of source]

where the misclassification losses $c_{01}$ and $c_{10}$ are now dependent on $x$ and $u$. Equivalently, decision maker $j$ also minimizes the ex ante expected loss:

align[align omitted — 183 chars of source]

The optimal decision rule is $\mathds{1}\(q_{j}\(x, u\right) > \frac{c_{01}\(x, u\right)}{c_{10}\(x, u\right) + c_{01}\(x, u\right)} \eqqcolon c_{j}\(x, u\right)\right)$. Consequently, for $\(x_{1}, u_1\right)$, $\(x_{2}, u_2\right)$ sharing the same propensity score $q_{j}\(x_{1}, u_1\right) = q_{j}\(x_{2}, u_2\right)$, the choice of the decision maker can be different due to cost differences: $c_{j}\(x_{1}, u_1\right) \neq c_{j}\(x_{2}, u_2\right)$. Such a decision rule is considered in elliott2013predicting. Even if all doctors have full information processing capacity, so that $q_j\(x,u\right)=p\(x,u\right)$ for a correctly specified propensity function $p\(x,u\right)$, an arbitrary FPR/TPR pair below the machine ROC curve can still be rationalized by some decision rule $\hat y = \mathds{1}\(p\(x,u\right) > c_j\(x,u\right)\right)$ corresponding to a reverse-engineered cost function $c_j\(x,u\right)$.

To illustrate using a synthetic example without $u$, let $x$ be uniformly distributed on $\left(0,1\right)$ and $p\(x\right) = x$. Let the cutoff threshold function be

align[align omitted — 161 chars of source]

Then $\hat y = \mathds{1}\(x < \frac12\right)$ and $(\text{TPR, FPR})=(1/8, 3/8)$, which lies strictly below the diagonal line. An example when the feature may enter into the cutoff threshold is bank lending, where $y \in \{0,1\}$ denotes whether a loan is paid back, and $\hat y \in \{0,1\}$ denotes whether a loan application is approved. The amount of principal and interests are features $x$ that are likely to affect the probability $p\(x\right)$ of defaulting by the borrower, but that are also likely to affect the cost perception $c\(x\right)$ by the lender. Assumption (ref) essentially excludes such difficulty of interpreting a FPR/TPR pair arising from incentive heterogeneity.

commentIn contrast, inter-individual incentive heterogeneity refers to a situation where decision makers differ in their perception of the relative costs between false positives and false negatives, but each of them applies the same threshold to their respective patients. More precisely, decision maker $j$ and $k$ may have $c_{j} \neq c_{k}$. However, the same $c_j$ is applied to all the patients of doctor $j$, and likewise for doctor $k$.

To understand whether the cost perception of doctors might vary systematically with the risk level of their patients, we use the FPR rank for each doctor to measure the conservativeness of their diagnoses. Doctors may be more willing to tolerate a higher FPR for higher risk patients when they perceive riskier patients as less healthy and more likely to incur a higher cost of underdiagnosis.

commentIntuitively, doctors may think people at higher risk are usually more unhealthy, and thus have higher costs of underdiagnosis when they get some illness. Under this situation, doctors may be more willing to undergo FPR when they are diagnosing higher risk patients.

We then estimate the correlation between the FPR ranks and a pregnancy risk level indicator. In particular, we regress $q_{i,j}$, the predicted abnormal birth rate for patients diagnosed by doctor $j$ from a random forest algorithm described in section (ref), against $r_j$, the doctor's FPR rank:

align[align omitted — 100 chars of source]

The doctors' FPR rank are normalized to $\left[0, 1\right]$. If the FPR of doctor $j$ is higher than 80% of the doctors, then $r_{j} = 0.8$. The regression results for doctors with no less than 300 diagnoses and for doctors with no less than 500 diagnoses are summarized in Table (ref). The regression results suggest that there is no strong evidence that the FPR rank of doctors is associated with the risk level of their patients.

table[table omitted — 1,996 chars of source]
comment{\color{purple}{ In kim2002limited, a semiparametric asymptotic Bayesian method is used an alternative to exact finite sample Bayesian analysis; the author combines a prior distribution for $\theta$ with the approximate normal distribution of $\hat\theta$ around $\theta$ to form a posterior distribution. This method can be formally justified by the convergence of the finite sample Bayesian posterior distribution to the approximate normal limit. See, for example, chernozhukov2003mcmc. For $\rho_L\left(\cdot,\cdot\right)$, a distance function that metrizes weak convergence, and for $\Sigma$ in Appendix A.3, {\begin{align}\begin{split}\nonumber \rho_L\(p\left(\sqrt{n}\left(\theta-\hat\theta\right) \vert Y\right) , N\left(0,\Sigma\right)\right) = o_P\left(1\right). \end{split}\end{align}} In other words, $p\left(\theta \vert Y\right) \overset{A}{\approx} N\left(\hat\theta, \hat\Sigma/n\right)$. The weak convergence can be strengthened to convergence in the moment total variation norm in chernozhukov2003mcmc. In addition to being obtained from the posterior distribution, $\hat\Sigma$ can also be obtained analytically or by bootstrapping. The entire distribution of $f_{\hat\theta-\theta_0}\left(\cdot\right)$ can also be estimated by bootstrapping. The asymptotic posterior distribution of $\theta$ by kim2002limited is defined through either {\begin{align}\begin{split}\nonumber p\left(\theta \vert \hat\theta\right) \propto \pi\left(\theta\right) \hat f_{\hat\theta-\theta_0}\left(\hat\theta-\theta\right)\quad{or}\quad p\left(\theta \vert \hat\theta\right) \propto \pi\left(\theta\right) \exp\left(- \frac{n}{2} \left(\theta-\hat\theta\right)'\hat\Sigma^{-1}\left(\theta-\hat\theta\right)\right). \end{split}\end{align}} The $1-\alpha$ confidence region $\hat S$ constructed by either the approximate normal distribution or bootstrapping corresponds, therefore, to the $1-\alpha$ Bayesian credible region by using a uniform prior distribution and similar constructions. The normal approximation does present the drawback that the support is not limited to $\left(0,1\right)$. However, for large sample sizes, confidence sets at conventional levels should reside well within $\left(0,1\right)$ with large probabilities.}}
commentThe Bayesian method also generalizes readily to multiclass settings. With more than two classes, the machine learning algorithm outputs a set of positive functions $p_j\(x\right), j=1,\ldots,J$ such that $\sum_{j=1}^J p_j\(x\right)=1, \forall x$, which we presume to be correctly specified conditional probabilities. The binary ROC curve now becomes a multiclass ROC surface (see, for example, maxvus), which collects the $J+1$ tuples of "TPRs" defined by \begin{align}\begin{split}\nonumber TPR_j\equiv \frac{E \bar y_j y_j}{E y_j} =\frac{ \int \prod_{k\neq j} 1\(b_j p_j\(x\right) \geq b_k p_k\(x\right)\right) p_j\(x\right) d F\(x\right) }{ p_j },\quadfor all\ j=1,\ldots,J \end{split}\end{align} where $\bar y_j = 1\(b_j p_j\(x\right) \geq b_k p_k\(x\right), \forall k \neq j\right)$, and when $b_j, j=1,\ldots,J$ vary freely over $R_+^{J}$. The sample observations for a doctor consist of $\(y_{ij}, \hat y_{ij}\right), i=1,\ldots,n, j=1,\ldots,J$. The $2J-1$ dimensional sample sufficient statistics for computing the doctor's TPR tuples are $\left(\hat t_{j1},\hat t_{j0}\right),j=1,\ldots,J$ with $\sum_{j=1}^J \sum_{l=0}^1 \hat t_{jl} = 1$, where \begin{align}\begin{split}\nonumber \hat t_{j1} = \frac1n \sum_{i=1}^n y_{ij} \hat y_{ij},\quad \hat t_{j1} = \frac1n \sum_{i=1}^n y_{ij} \left(1-\hat y_{ij}\right),\quad \left(\hat t_{j1}, \hat t_{j0}\right) \overset{p}{\rightarrow} \left(\hat t_{j1}=E y_j \hat y_j, \hat t_{j0} = E y_j \left(1-\hat y_j\right)\right). \end{split}\end{align} As before for $\theta=\left(\theta_j=E \hat y_j y_j/p_j, j=1,\ldots,J\right)$ and $t=\(t_{j1},t_{j0},j=1,\ldots,J\right)$, we can write $\theta=h\(t\right)$, and the same Dirichlet conjugate prior on the $K=2J$ simplex can be used to simulate the posterior distribution of both $t$ and $\theta$, namely, $p\(t \vert Y\right)$ and $p\left(\theta \vert Y\right)$. Then, (ref) can be revised to, for example, $\rho\(w, \theta\right)=\mathds{1}-\mathds{1}\left(\theta_j\leq w_j, \forall j\right)$, {\begin{align}\begin{split} \min_{w \in ROC surface} \int \rho\(w, \theta\right) p\left(\theta\vert Y\right) d\theta \approx \frac1R \sum_{r=1}^R \rho\(w, \theta_r\right). \end{split}\end{align}} Often, $\rho\(w, \theta\right)$ is decreasing in $w$, in which case, (ref) is equivalent to {\begin{align}\begin{split} \min_{w\ below or on the\ ROC surface} \int \rho\(w, \theta\right) p\left(\theta\vert Y\right) d\theta \approx \frac1R \sum_{r=1}^R \rho\(w, \theta_r\right). \end{split}\end{align}} A necessary step for implementing (ref) is to check whether a given $w$ is below the ROC surface. As in duality, implementing this step amounts to determining the feasibility of a linear program that seeks the existence of functions $0 \leq \phi_j\(x\right) \leq 1, j=1,\ldots,J$, $\sum_{j=1}^J \phi_j\(x\right) = 1, \forall x$, such that \begin{align}\begin{split} E \phi_j\(X\right) p_j\(X\right) / p_j \geq w_j, \forall j=1,\ldots,J. \end{split}\end{align} Given inputs of $f\(X\right),p_j\(X\right),j=1,\ldots,J$, algorithms for verifying this condition are available in the linear programming literature. A multiclass Bayesian algorithm can therefore be summarized as follows: \begin{enumerate} • Draw a dense set of $\bar t^s, s=1,\ldots,\bar R$ from the $2J$ unit simplex $\sum_{j=1}^J \sum_{l=0}^1 \bar t^s_{jl}=1$. Compute the corresponding $w^s = \theta\(t^s\right)$. • Retain the subset of $w^s$ that satisfies the feasibility condition of (ref). • Among the retained set, choose $w^s$ that minimize (ref). \end{enumerate}
comment{\color{purple}{ More elaborate algorithms can potentially improve accuracy and convergence speed. Furthermore, the multiclass ROC surface can be generalized to allow for off-diagonal elements of misclassification rates, i.e., $E y_{j} \hat y_k / p_j$ for all $k \neq j$. We leave the possibility of such a further extension for future investigation. }}
commentWe initially experiment{\color{red}{ed}} with a heuristic procedure, which is described as follows. \begin{itemize} • Form a confidence set $\hat S$ for {\color{blue}{$\theta_{H}$}} {\color{red}{$\theta_0$}}, for example, based on bootstrapping or the asymptotic normal distribution of {\color{blue}{$\hat{\theta}_{H}$}} {\color{red}{$\hat\theta$}} around {\color{blue}{$\theta_{H}$}} {\color{red}{$\theta_0$}}. • For each $s\in \hat S$, define {\color{blue}{ \begin{align}\begin{split} A_s = \{\theta = \left(\alpha, \beta\right): \alpha \leq s_1, \beta \geq s_2\}. \end{split}\end{align}}} In other words, $A_s$ is the set of points that are {\it better} than $s$ (i.e., the points in $A_s$ have a lower FPR and a higher TPR). • Next, define {\color{blue}{$A = \bigcap_{s \in \hat{S}} A_s$}} {\color{red}{$A = \Cap_{s \in \hat S} A_s$ (Why $\Cap$ ?)}}, where $A$ is the set of points {\it better} than all the points in $\hat S$ in the above sense. • Next, define $\bar A = A \cap \text{ROC}$, {\color{blue}{i.e}} {\color{red}{I.e.}}, $\bar A$ is the set of ROC points that simultaneously dominate all the points in $\hat S$. \end{itemize} Conventional confidence {\color{red}{and credibility}} levels suggest the need to be conservative when making decisions to replace humans with machines. Specifically, only when $\bar A \neq \emptyset$, i.e., when, on the machine's ROC curve, there exists a point that is better than any point in a confidence set of the human FPR/TPR {\color{blue}{pair}} of a given confidence level, the machine's decision is considered to be better than the human's decision with the corresponding level of confidence. In other words, we will replace the human's decision with the machine's only when a sufficiently large portion of the FPR/TPR joint distribution is {\color{blue}{dominated by}} {\color{red}{below}} the machine ROC curve {\color{blue}{in the sense of (ref)}}. To illustrate, consider a typical oval-shaped confidence region based on the asymptotic normal distribution of the estimated human {\color{blue}{FPR/TPR pair $\hat{\theta}_{H}$}}. The following discussion also applies to alternative confidence regions of different shapes. Denote by {\color{blue}{$\left(\alpha_{\beta_{high}}, \beta_{high}\right)$}} {\color{red}{$(HFPR_1,HTPR_H)$}} the point that corresponds to the highest TPR on the oval, and denote by {\color{blue}{$\alpha_{low}, \beta_{\alpha_{low}}$}} {\color{red}{$(HFPR_S,HTPR_2)$}} the point that corresponds to the smallest FPR on the oval. The point {\color{blue}{$\left(\alpha_{low}, \beta_{high}\right)$}} {\color{red}{$(HFPR_S,HTPR_H)$}} corresponds to P in Figure (ref). Regarding the position of the human oval shape and the machine ROC curve, there are three cases. \begin{enumerate} • Case 1: The human oval area and point {\color{blue}{$\left(\alpha_{low}, \beta_{high}\right)$}} {\color{red}{$(HFPR_S,HTPR_H)$}} are all below the ROC curve. In this case, the human decision maker performs "worse" than the machine and hence can be replaced by the machine. This case corresponds to Figure (ref). In this case, on the ROC curve, one can find two points, namely, {\color{blue}{$\left(\alpha_{R}, \beta_{high}\right)$}} {\color{red}{$(RFPR_1,HTPR_H)$}} and {\color{blue}{$\left(\alpha_{low}, \beta_{R}\right)$}} {\color{red}{$(HFPR_S,RTPR_2)$}}, corresponding to points B and A in Figure (ref). Any point from A to B corresponds to a better machine decision. • Case 2: The entire human oval confidence area is below the ROC curve, but the point {\color{blue}{$\left(\alpha_{low}, \beta_{high}\right)$}} {\color{red}{$(HFPR_S,HTPR_H)$}} is above the ROC curve. In this case, although different points on the machine ROC curve can achieve a better decision than different points in the confidence region of the human FPR/TPR pair, on the machine ROC curve, one cannot find a nonempty fraction that is better than all the points in the human's confidence set to account for the randomness of the estimated human FPR/TPR pair {\color{blue}{and the implicit arbitrariness of the cost matrix}}. In this case, which corresponds to Figure (ref), the human decision maker is not replaced by machine. • Case 3: The human oval area has a certain area above the machine's ROC curve; therefore, the human decision maker is not replaced by a machine possibly because either the human decision maker is sufficiently capable or his/her FPR/TPR pair is not measured precisely enough, for example, due to a lack of historical data, thus making the confidence area (oval) quite large. This case corresponds to Figure (ref). \end{enumerate} In summary, if the P point {\color{blue}{$\left(\alpha_{low}, \beta_{high}\right)$}} {\color{red}{$(HFPR_S,HTPR_H)$}} is below the ROC curve, the human decision maker is replaced; otherwise, he/she is not. \begin{figure} \caption{Sketch Map of Our Method for A Single Decision Maker: Case 2} \end{figure} \begin{figure} \caption{Sketch Map of Our Method for A Single Decision Maker: Case 3} \end{figure} In Appendix A.5, we relax the requirement that less-capable humans deterministically follow the decision obtained by using AI (or are replaced by AI) and allow for an acceptance probability, i.e., $\lambda \in [0,1]$, with which less-capable humans are randomized into following the decisions obtained by using AI. These humans adhere to their own ideas when $\lambda$ equals 0 and always follow AI when $\lambda$ equals 1. {\color{brown}{ ToDo: Add a simulation (or simulations) that doctors use AI according to they capacities, for example, less-capable doctors accept AI with higher probability than high-performing doctors (or vice versa). }} A question arises as to the provision of a statistical and probabilistic statement justifying this procedure. In a classical approach, {\color{blue}{$\theta_{H}$}} {\color{red}{$\theta_0$}} is a fixed number and not a random variable. {\color{blue}{$\theta_{H}$}} {\color{red}{$\theta_0$}} is either above or below the ROC, without an associated probability. The confidence set itself is a random set, such that {\color{blue}{$\mathbb{P}\left(\theta_H \in \hat S\right) \approx 1-\alpha.$}} Namely, {\color{blue}{for the conventional level of $\alpha = 0.05$,}} if the confidence set is to be constructed 100 times from different samples, $\hat S$ will contain $\theta_0$ approximately 95 times. Consequently, $\bar A$ is a random set such that asymptotically, {\color{blue}{$\mathbb{P}\left( \text{all points on $\bar A$ dominate $\theta_H$} \right) \geq 1-\alpha.$}} However, this situation can be difficult to interpret since $\bar A$ can be empty even when $\hat S$ lies entirely below the ROC. {\color{red}{What}} {\color{blue}{The}} probability of the random event of $\bar A \neq \emptyset$, i.e., $\mathbb{P}\left(\bar A \neq \emptyset\right)$, {\color{red}{depends on}} is unknown but can be estimated, for example, by bootstrap iteration. Depending on the true data generating process, $\mathbb{P}\left(\bar A \neq\emptyset\right)$ can be anywhere between $0$ and $1$.
commentA confidence set is often also a posterior credible region with a diffuse prior. In the Bayesian setting, the statement that $\bar A \neq \emptyset$ can be interpreted as the existence of a ROC point that simultaneously dominates 95% of the posterior distribution of $\theta$. A Bayesian method can do more than construct a posterior credible region. As discussed before, the posterior probability that $\theta$ lies below the ROC can be computed by using numerical integration or estimated by using simulations. In the classical/frequentist framework, {\color{blue}{$\theta_{H}$}} {\color{red}{$\theta_0$}} is a fixed number and not a random variable, and we are not allowed to make probabilistic statements about {\color{blue}{$\theta_{H}$}} {\color{red}{$\theta_0$}}. We therefore turn to a setup of formulating tests of a composite null versus a composite alternative hypothesis: \begin{align}\begin{split} H_0: {\color{blue}{\theta_{H}}} {\color{red}{\theta_0}} \ lies below the ROC\quadagainst\quad H_1: {\color{blue}{\theta_{H}}} {\color{red}{\theta_0}} \ lies above the ROC. \end{split}\end{align} The roles of the null and alternative hypotheses can be reversed, depending on which one we are more willing to theorize on, {\it a priori}. Suppose we represent the ROC curve by {\color{blue}{$\beta = g\left(\alpha\right)$, where $g\left(\cdot\right)$}} is known, increasing, and concave. Then, we can rewrite {\color{blue}{ \begin{align}\begin{split}\nonumber H_0: \beta_{H} < g\left(\alpha_{H}\right) \quadagainst\quad H_1: \beta_{H} \geq g\left(\alpha_{H}\right). \end{split}\end{align}}} Let $t=\beta - g\left(\alpha\right)$; then, the hypotheses can be restated as {\color{blue}{ \begin{align}\begin{split}\nonumber H_0: t_0 < 0 \quadagainst \quad H_1: t_0 \geq 0. \end{split}\end{align}}} An asymptotic test can then be based on combining the Delta method with a one-sided t-test. For {\color{blue}{$G_{H} = g'\left(\alpha_{H}\right)$, $B = \left(-G_{H}, 1\right)$}}, it can be shown that\footnote{In the rest of the paper, we assume that $g\left(\cdot\right)$ is continuously differentiable; this situation holds when $p\(X\right)$ is continuously distributed in the population. Discretely distributed $p\(X\right)$ might result in $g\(x\right)$ that are only directionally differentiable and might require a numerical version of the Delta method. Inference methods that can be based on results from the moment inequality testing literature are applicable. See, for example, andrews2013inference, fang2019inference, hong2018numerical, and hong2020numerical. } {\begin{align}\begin{split}\nonumber \sqrt{n}\left(\hat t - t_0\right) \overset{d}{\longrightarrow} N\left(0, B \Sigma B'\right). \end{split}\end{align}} Let {\color{blue}{$\hat G = g'\left(\hat{\alpha}_{H}\right)$}}, $\hat B = \left(-\hat{G}, 1\right)$, {\color{blue}{$\hat\Sigma \overset{\mathbb{P}}{\rightarrow} \Sigma$}}, and $z_{1-\alpha}$ be the standard normal $1-\alpha$ percentile: {\color{blue}{ \begin{align}\begin{split}\nonumber \mathbb{P}\left( \frac{ \sqrt{n}\left(\hat t - t_0\right) }{ \sqrt{ \hat B \hat\Sigma \hat B' } } \geq z_{1-\alpha} \right)\rightarrow \alpha \end{split}\end{align}}} Rejecting a decision when $\sqrt{n} \hat t / \sqrt{ \hat B \hat\Sigma\hat B' } > z_{1-\alpha}$ is then an approximate size $\alpha$ test. For conventional levels of $\alpha$, we typically do not reject a decision when $\hat t \leq 0$. More generally, a typical test rejects a decision when $\hat t \geq \hat c_{1-\alpha}$, for a suitable chosen $\hat c_{1-\alpha}$ such that {\color{blue}{\begin{align}\begin{split}\nonumber \mathbb{P}\left( \hat t \geq \hat c_{1-\alpha} \vert t_0 = 0 \right) \rightarrow \alpha. \end{split}\end{align}}} The analytic Delta method sets $\hat c_{1-\alpha} = \sqrt{ \frac{\hat B \hat\Omega \hat B'}{n} } z_{1-\alpha}$. There are alternative implementations of $\hat c_{1-\alpha}$. {\color{purple}{One is the so-called asymptotic delta method: for large $R$, draw for $r=1,\ldots,R$, $\omega_r$ from $N\left(0, \hat\Sigma/n\right)$. Set $\hat c_{1-\alpha}$ as the $1-\alpha$ percentile of the empirical distribution of \begin{align}\begin{split}\nonumber \hat\theta_2 + \omega_{2r} - g\left(\hat\theta_1 + \omega_{1r}\right) - \left(\hat\theta_2- g\left(\hat\theta_1\right)\right) \end{split}\end{align} Another alternative is bootstrapping.}} {\color{blue}{Bootstrapping is popular, set $\hat c_{1-\alpha}$ to the $1-\alpha$ percentile of the empirical distribution of $\tilde{t}_b - \hat t, b=1,\ldots,B$, where $\hat t_b$'s are bootstrapped replications of $\hat t$.}} For completeness, we also describe the reverse testing problem: {\color{blue}{ \begin{align}\begin{split} H_0: \alpha_{H} \ lies above ROC\quad\text{against}\quad H_1: \alpha_{H} \ \text{lies below ROC}. \end{split}\end{align}}} Replacing a human decision maker with the machine is appropriate only when there is {\it overwhelming} evidence that the machine performs better. A priori, \emph{we maintain confidence in human beings} unless there is strong evidence suggesting otherwise.
comment{\color{blue}{ \begin{align}\begin{split}\nonumber H_0: \beta_{H} \geq g\left(\alpha_{H}\right) \quadagainst\quad H_1: \beta_{H} < g\left(\alpha_{H}\right). \end{split}\end{align}}} Let $t = \beta - g\left(\alpha\right)$; then, the hypotheses can be restated as \begin{align}\begin{split}\nonumber H_0: t_0 \geq 0 \quadagainst\quad H_1: t_0 < 0. \end{split}\end{align} We reject a decision if $\hat t \leq \hat c_\alpha$. {\color{purple}{There are several choices for $\hat c_\alpha$. The first choice is the analytic Delta method, where $\hat c_\alpha = z_\alpha \sqrt{\hat B \hat\Sigma\hat B'/ n}$. The second choice is the asymptotic Delta method: for large $R$, draw for $r=1,\ldots,R$, $\omega_r$ from $N\left(0, \hat\Sigma/n\right)$. Set $\hat c_{\alpha}$ to the $\alpha$ percentile of the empirical distribution of $\hat\theta_2 + \omega_{2r} - g\left(\hat\theta_1 + \omega_{1r}\right) - \left(\hat\theta_2- g\left(\hat\theta_1\right)\right)$. The third option is bootstrapping. Set $\hat c_{\alpha}$ to the $\alpha$ percentile of the empirical distribution of $\hat t_b - \hat t, b=1,\ldots,B$, where $\hat t_b$'s are bootstrapped replications of $\hat t$.}} {\color{brown}{ToDo: Add an experiment to see how many doctors are not as good as the machine.}} Using conventional confidence sets to construct tests of $H_0$ against $H_1$ in (ref) will likely generate issues. Recall that a conventional confidence set is given asymptotically by {\color{blue}{ \begin{align}\begin{split}\nonumber \left\{\theta: n \left(\theta-\hat{\theta}_{H}\right)'\hat\Sigma^{-1} \left(\theta-\hat{\theta}_{H}\right) \leq \chi^2_{2,1-\alpha}\right\}, \end{split}\end{align}}} Consider the following alternatives. \begin{itemize} • Test 1 (T1): Reject a decision if {\color{blue}{$\hat{\beta}_{H} > g\left(\hat{\alpha}_{H}\right)$ and $\left(\hat{\alpha}_{H}, g\left(\hat{\alpha}_{H}\right)\right)$}} is below the confidence set. • Test 2 (T2): Reject a decision if the entire confidence set lies above the ROC. • Test 3 (T3): Reject a decision if a point on the ROC is simultaneously dominated by all points on the confidence set. \end{itemize} T1 rejects a decision if {\color{blue}{$\hat{\beta}_{H} > g\left(\hat{\alpha}_{H}\right)$ and if $n \left[\hat \Sigma^{-1}\right]_{2,2} \left(\hat{\beta}_{H} - g\left(\hat{\alpha}_{H}\right)\right)^2 \geq \chi^2_{2,1-\alpha}$}}. {\color{purple}{Note that $\left[\hat \Omega^{-1}\right]_{2,2} = \left(\sigma_{22} - \frac{\sigma_{12}^2}{\sigma_{11}}\right)^{-1}$. However, under the least favorable null: \begin{align}\begin{split}\nonumber \hat\theta_2 - g\left(\hat\theta_1\right) \approx \hat\theta_2 - \theta_2 - G_0\left(\hat\theta_1 - \theta_1\right) \sim N\left(0, \sigma_{22} + G_0^2 \sigma_{11} - 2 G_0 \sigma_{12}\right). \end{split}\end{align}}} The test statistic distribution is not $\chi_2^2$ and is unlikely to have the correct size. T2 rejects a decision if $\hat\theta_2 > g\left(\hat\theta_1\right)$ and if $\inf_{x: x_2 = g\(x_1\right)} n \(x - \hat\theta\right)' \hat\Omega\(x - \hat\theta\right) \geq \chi^2_{2, 1-\alpha}.$ The left-hand side is the J-statistic for one overidentifying restriction and has an asymptotic $\chi_1^2$ distribution (not $\chi_2^2$). Since $\chi^2_{2,1-\alpha} \geq \chi^2_{1,1-\alpha}$, the null rejection probability is less than $\alpha$. Therefore, this test is conservatively valid (undersized) and is likely to be less powerful. This result is in addition to the power loss from essentially using a two-sided test for a one-sided hypothesis. T3 is obviously even more conservative than T2. Therefore, T3 will be undersized and less powerful. The same issues also concern mirror versions of T1 to T3 for testing (ref). More generally, confidence sets that favor the machine over human decision makers can be constructed by inverting two-dimensional inequality tests of the form of \begin{align}\begin{split}\nonumber H_0: \theta_1 \leq \theta_{10}\quadand\quad \theta_2 \geq \theta_{20}\quadagainst\quad H_1: not\ H_0. \end{split}\end{align} For example, a size $\alpha$ test that rejects a decision when $\hat\theta_1 \geq \theta_{10} + a\quad\text{or}\quad \hat\theta_2 \leq \theta_{20} - b.$ corresponds to a confidence set of the form of $\hat S = \{\theta: \theta_1 \geq \hat\theta_1 - a\quad\text{and}\quad \theta_2 \leq \hat\theta_2 +b\}.$ For a given pair of ($a$, $b$), the coverage probability can be estimated by using simulation or by bootstrapping. An additional restriction is still needed to uniquely determine $(a,b)$. One possibility is to limit to $a=b$. An alternative is to {\color{red}{minimize (maximize?)}} the expected length of $\bar A = A \cap \text{ROC}$. Note that $\bar A \neq \emptyset$ when $\hat\theta^2 +b \leq g\left(\hat\theta_1 - a\right)$, where it is bracketed by two end points $g^{-1}\left(\hat\theta_2 + b\right)$ and $\hat\theta_1-a$. Then, $\text{len}\left(\bar A\right) = \int_{g^{-1}\left(\hat\theta^2 +b\right)}^{\hat\theta_1-b} \sqrt{1 + g'\(x\right)^2} dx.$ The formal program is \begin{align}\begin{split}\nonumber &\max_{a,b} \mathbb{E} \int_{g^{-1}\left(\hat\theta_2 + b\right)}^{\hat\theta_1 - a} \sqrt{1 + g'\(x\right)^2} dx\\ &such that\quad P\left(\hat \theta_1 - \theta_{10} \leq a, \hat \theta_2 - \theta_{20} \geq -a\right) = 1-\alpha \end{split}\end{align} This program depends on the unknown underlying the data generating process, A feasible version can be estimated by bootstrapping: Let $\mathbb{E}^*$, $P^*$, and $\hat\theta^*$ denote bootstrap versions of their sample analogs: \begin{align}\begin{split}\nonumber &\max_{a,b} \mathbb{E}^* \int_{g^{-1}\left(\hat\theta_2^* + b\right)}^{\hat\theta_1^* - a} \sqrt{1 + g'\(x\right)^2} dx\\ &\text{such that}\quad P^*\left(\hat \theta_1^* - \hat\theta_{1} \leq a, \hat \theta_2^* - \hat\theta_{2} \geq -b\right) = 1-\alpha. \end{split}\end{align} As in the Bayesian method, given a decision to replace a human decision maker with the machine learning algorithm, we are also interested in finding the {\it best} point on the ROC. In the Bayesian setting, we suggested (ref). Such a point is harder to interpret in the frequentist approach. In the following, we discuss a few heuristic procedures. In the first approach, on the ROC curve we look for pairs $\(a,b\right)$ that maximize the following probability of dominating the estimated parameters: $P\left(\hat\theta_1 \geq a, \hat\theta_2 \leq b\right)$. This coverage probability can be estimated by bootstrapping $P^*\left(\hat\theta_1^* \geq a, \hat\theta_2^* \leq b\right).$ An implementable program is, therefore, \begin{align}\begin{split} \max_{b=g\(a\right)} P^*\left(\hat\theta_1^* \geq a, \hat\theta_2^* \leq b\right). \end{split}\end{align} Alternative approaches can be based on the inversion of test statistics and bootstrapping P-values. First, we formulate a null hypothesis for the superiority (or lack of superiority) of machine over humans and a corresponding testing procedure. Next, we use bootstrapping to compute the P-value of the test and locate the pair of $a, b=g\(a\right)$ that optimizes the bootstrapped P-value in favor of a decision of replacing humans with machines. Different setups are presented below. \paragraph{Framework 1} For each $a, b=g\(a\right)$, let $H_0$ be $\{\theta_{10} \leq a\ \text{or}\ \theta_{20} \geq b\}$. $H_1$ negates $H_0$. In other words, $H_0$ states that humans are not worse than machines. We want to minimize a bootstrapped P-value of a test procedure because a rejection means the machine is better, and a small P-value indicates stronger data evidence for rejection. A natural rejection area is $R = \{ \hat\theta_1 \geq c_a\ \text{and}\ \hat\theta_2 \leq c_b\}.$ For each pair of $c_a$ and $c_b$, the rejection probability under $\theta_0=\(a,b\right)$, $P\left( \hat\theta_1 - a \geq c_a - a\ \text{and}\ \hat\theta_2 - b\leq c_b - b \right)$ can be estimated by bootstrapping: $P^*\left( \hat\theta_1^* - \hat\theta_1 \geq c_a - a\ \text{and}\ \hat\theta_2^* - \hat\theta_2\leq c_b - b \right)$. The bootstrapped P-value is thus \begin{align}\begin{split}\nonumber P^*\left( \hat\theta_1^* - \hat\theta_1 \geq \hat\theta_1 - a\ \text{and}\ \hat\theta_2^* - \hat\theta_2\leq \hat\theta_2 - b \right) = P^*\left( \hat\theta_1^* \geq 2 \hat\theta_1 - a\ \text{and}\ \hat\theta_2^* \leq 2 \hat\theta_2 - b \right) \end{split}\end{align} The program to implement is then \begin{align}\begin{split} \min_{b = g\(a\right)} P^*\left( \hat\theta_1^* \geq 2 \hat\theta_1 - a\ \text{and}\ \hat\theta_2^* \leq 2 \hat\theta_2 - b \right) \end{split}\end{align} The machine is chosen if the minimized value is smaller than the given size (e.g., 5%).
commentFramework 2: For each $a, b=g\(a\right)$, let $H_0$ be $\{\theta_{10} \geq a\ \text{or}\ \theta_{20} \leq b\}$. $H_1$ negates $H_0$. In other words, $H_0$ states that machines are not worse than humans. Rejection means that the machine is worse than humans or that humans are better than the machine. In cases of rejection, do not replace humans with the machine; replace humans with the machine only when there is a failure to reject. We want to maximize a bootstrapped P-value of a test procedure because rejection means humans are better and a large P-value means the data provide the weakest evidence for rejection or the strongest evidence for replacing humans with the machine. A natural rejection area (although its optimality remains to be investigated) is {\begin{align}\begin{split}\nonumber R = \{ \hat\theta_1 \leq c_a\ and\ \hat\theta_2 \geq c_b\}. \end{split}\end{align}} For each pair of $c_a$, $c_b$, the rejection probability under $\theta_0=\(a,b\right)$ (not proven yet to be the least favorable null), {\begin{align}\begin{split}\nonumber P\left( \hat\theta_1 - a \leq c_a - a\ and\ \hat\theta_2 - b\geq c_b - b \right) \end{split}\end{align}} can be estimated by bootstrapping: {\begin{align}\begin{split}\nonumber P^*\left( \hat\theta_1^* - \hat\theta_1 \leq c_a - a\ and\ \hat\theta_2^* - \hat\theta_2\geq c_b - b \right) \end{split}\end{align}} The bootstrapped P-value is thus {\begin{align}\begin{split}\nonumber P^*\left( \hat\theta_1^* - \hat\theta_1 \leq \hat\theta_1 - a\ and\ \hat\theta_2^* - \hat\theta_2\geq \hat\theta_2 - b \right) = P^*\left( \hat\theta_1^* \leq 2 \hat\theta_1 - a\ and\ \hat\theta_2^* - \geq 2 \hat\theta_2 - b \right) \end{split}\end{align}} The program to implement is then {\begin{align}\begin{split} \max_{b = g\(a\right)} P^*\left( \hat\theta_1^* \leq 2 \hat\theta_1 - a\ \text{and}\ \hat\theta_2^* \geq 2 \hat\theta_2 - b \right) \end{split}\end{align}} The machine is chosen if the maximized value is greater than the given desired level.
comment\paragraph{Framework 2} For each $a, b=g\(a\right)$, let $H_0$ be $\{\theta_{10} \leq a\ \text{and}\ \theta_{20} \geq b\}$. $H_1$ negates $H_0$. In other words, $H_0$ states that humans are better than machines. Rejection means humans are not better than the machine. We want to minimize a bootstrapped P-value of a test procedure because rejection means humans are not better than the machine, and a small P-value indicates strong data evidence for rejection. A natural rejection area is $R = \{ \hat\theta_1 \geq c_a\ \text{or}\ \hat\theta_2 \leq c_b\}.$ For each pair of $\(c_a, c_b\right)$, the rejection probability under $\theta_0=\(a,b\right)$, $P\left( \hat\theta_1 - a \geq c_a - a\ \text{or}\ \hat\theta_2 - b\leq c_b - b \right)$ can be estimated by bootstrapping: $P^*\left( \hat\theta_1^* - \hat\theta_1 \geq c_a - a\ \text{or}\ \hat\theta_2^* - \hat\theta_2\leq c_b - b \right)$. The bootstrapped P-value is thus \begin{align}\begin{split}\nonumber P^*\left( \hat\theta_1^* - \hat\theta_1 \geq \hat\theta_1 - a\ or\ \hat\theta_2^* - \hat\theta_2\leq \hat\theta_2 - b \right) = P^*\left( \hat\theta_1^* \geq 2 \hat\theta_1 - a\ or\ \hat\theta_2^* \leq 2 \hat\theta_2 - b \right) \end{split}\end{align} The program to implement is then \begin{align}\begin{split} \min_{b = g\(a\right)} P^*\left( \hat\theta_1^* \geq 2 \hat\theta_1 - a\ or\ \hat\theta_2^* \leq 2 \hat\theta_2 - b \right) \end{split}\end{align} The machine is chosen if the minimized value is smaller than a given level. Note that (ref) can be equivalently written as \begin{align}\begin{split} \max_{b = g\(a\right)} P^*\left( \hat\theta_1^* \leq 2 \hat\theta_1 - a\ and\ \hat\theta_2^* \geq 2 \hat\theta_2 - b \right) \end{split}\end{align} A large body of literature on testing multivariate equalities is based on penalizing objective functions. These testing procedures can potentially be used to generate programs that optimize the P-value along $a, b=g\(a\right)$ to select the optimal point on the machine ROC.
comment\subsection{Replacement of a Subset of Human Decision Makers} The Bayesian approach and frequentist approach translate into related algorithms for replacing a subset of the human decision makers. First, a Bayesian approach can compute (ref) and replaces a human decision maker with the machine when (ref) is larger than a given confidence level. Second, both the Bayesian approach and the frequentist approach can provide confidence sets (also called credible sets in the Bayesian setting). These confidence set procedures also translate into algorithms for replacing a subset of the human decision makers. The following provides more details.

The use of statistical significance as a benchmark for comparing doctors with the machine algorithm is motivated by the difficulty of fixating a social cost function, even if we assume that informed human decision makers are fully rational and impose strong functional form assumptions. Designing a social loss function empirically relies on the domain knowledge of the specific decision maker. Our replacement algorithm allows for the choice of the cutoff threshold to be specific to each individual doctor, and does not require a homogeneous preference function to be applied to all doctors. The baseline comparison between true positive rates and false positve rates can also potentially mask the severity of individual cases, the identification of which requires a richer dataset with more precise measurements on the outcome variable. While these information are not available in our dataset, exploring richer data information can be a fruitful future direction of research.

A responsible phase-in protocol based on multiple years of data on performance observations can incorporate long term health and wellbeing outcomes into the definition of performance and quality for decision making. Our data is cross-sectional and does not follow doctors or patients over time. When a panel data becomes available in which doctors and patients can be observed over multiple time periods, future work can potentially generalize the current approach to allow for sequential testing and decision making. The challenge of accounting for longer term health outcomes is partially reflected by the current strategy that replaces a doctor’s diagnosis by the machine algorithm only when there is overwhelming statistical evidence suggesting the superiority of the machine decision.

Data and Algorithm Description

Our data came from the National Free Prepregnancy Checkups (NFPC) project. Starting from 2010, NFPC offers free health checkup for couples planning to conceive and is conducted across 31 provinces in China. The dataset contains more than 300 features for each observation, including age, demographic characteristics, results from medical examinations and clinical tests, disease and medication history, pregnancy history, lifestyle and environmental information of both wives and husbands. The data also include the birth outcome, which is denoted as normal ($y = 0$) or abnormal ($y = 1$). In addition, the dataset records doctors' IDs and diagnoses of pregnancy risk. The doctors' diagnoses are graded according to 4 levels: 0 for normal, 1 for high-risk wife, 2 for high-risk husband, and 3 for high-risk wife and husband. In this paper, we group the doctor's diagnoses into 2 categories, where a grade of 0 corresponds to normal pregnancy and any higher grade corresponds to a diagnosis of risky pregnancy.

Our original dataset includes 3,330,304 couples that have pregnancy outcomes between January 1, 2014, and December 31, 2015. We exclude duplicate features and samples for which either doctors' diagnoses or more than 50% of feature values are missing. We were left with 168 features of 1,137,010 couples who were diagnosed by 28,716 doctors. Of these observations, 61,184 couples (5.38%) had abnormal birth outcomes.

A basic measurement of the prediction quality of a binary classifier is accuracy, which is the proportion of correct predictions. However, accuracy itself is inadequate in many applications. As the adverse birth rate is about 5%, a naive classifier that categorizes all cases as low risk would achieve an accuracy of nearly 95%. This is clearly controversial. The doctors' overall accuracy is 73.63%, and 24.04% of pregnancies are diagnosed as high-risk. Doctors' aggregate false positive rate and true positive rate are 0.2379 and 0.2843. In contrast, the FPR and TPR of the naive predictor are both zero. In other words, doctors are willing to tolerate a higher FPR in order to achieve a higher TPR.

We focus on doctors who diagnosed more than 300 patients. There are 584 such doctors corresponding to 584,181 patient cases. Using a ratio of 7:3 and stratification methods, we randomly split our sample into a classification set and a performance set. We use the classification set to train a machine learning algorithm, and then we categorize a doctor as “replaced” or “retained” according to our statistical procedure. The performance set is used to compute the FPR/TPR of the combined diagnoses. The data cases are stratified into the four classes based on the actual birth outcomes and the doctors' diagnoses: true positive cases, true negative cases, false negative cases and false positive cases. The random splitting process is performed through each class of data with the same ratio of 7:3. Subsequently, the data in each class are merged to form the classification and performance sets. In total, there are 408,661 cases in the classification set and 175,520 cases in the performance set.

We further split the classification set into two subsets. The first subset is the training set used to estimate the parameters in a machine learning algorithm. The second subset is the validation set used to evaluate the performance of the algorithm and obtain the machine ROC curve. Splitting of the classification set into the training and validation subsets is done using a ratio of 4:3 and the same stratification method described above. There are 233,435 cases in the training set and 175,226 cases in the validation set.

commentTo check the robustness of our approaches we also conduct the experiments based on doctors who diagnosed more than 500 patients. We have 367 such doctors and 495,320 cases in total. For the classification set, we have 197,978 patient cases in the training sample and 148,579 patient cases in the validation sample. Altogether, 346,557 cases are used as historical records for finding less capable doctors. For the performance set, we have 148,763 cases for evaluating the performance of doctors and the algorithm.

We experimented with several algorithms. We begin with decision trees, which are widely used in many machine learning applications. However, a single tree method usually has high variance despite its low bias, and tends to overfit by generating results with substantial variation even when a small amount of noise is present in the data. In contrast, random forest (RF) is a commonly used ensemble learning algorithm proposed by breiman2001random, and overcomes these problems by constructing a collection of decision trees that are trained using different feature subspaces and bootstrapped samples. The predictions of each tree are aggregated to make predictions. Appendix (ref) provides more details about the random forest algorithm.\footnote{We choose the following parameter settings. The number of estimators $N$ is $100$. The number of max features per node $M$ is $50$. The minimum number of samples required to split is 50.}

remarkThe classification of doctors' diagnoses by both husband and wife raises a question regarding the validity of Assumption (ref) that rules out intra-individual incentive heterogeneity, if the relative costs of false positives to false negatives differ between when a single person is deemed risky and when both are deemed risky. A multiclass classification model with four outcome labels differentiating abnormal pregnancy outcomes due to high risks in wife, husband and both spouses can allow for heterogeneous relative costs of false positives to false negatives across these cases. However, in our dataset, the outcome label is only binary indicating whether the birth is classified as normal or abnormal. The lack of the corresponding four-way outcome label makes it difficult to compute an accurate TPR and FPR for each of the diagnosis class. As an illustration, we empirically calculate the FPR/TPR using the binary outcome label for each of the four diagnosis cases, and report the aggregate summary in the following table: \begin{table}[htbp] \caption{Doctor performance summary by multiple diagnosis classes} \begin{tabular}{cccccccc} \toprule \multicolumn{8}{l}{Panel A: FPRs for different diagnosis classes} \\ \midrule min patient cases & num negative & FP1 & FP2 & FP3 & FPR1 & FPR2 & FPR3 \\ \midrule 300 & 554195 & 51896 & 33266 & 20954 & 0.0934 & 0.0600 & 0.0524 \\ 500 & 470562 & 42636 & 27362 & 21233 & 0.0906 & 0.0581 & 0.0451 \\ \toprule \multicolumn{8}{l}{Panel B: TPRs for different diagnosis classes} \\ \midrule min patient cases & num positive & TP1 & TP2 & TP3 & TPR1 & TPR2 & TPR3 \\ \midrule 300 & 29986 & 3250 & 1750 & 1941 & 0.108 & 0.0584 & 0.0647 \\ 500 & 24758 & 2589 & 1384 & 1412 & 0.104 & 0.0559 & 0.0570 \\ \toprule \multicolumn{8}{l}{Panel C: Precisions across diagnosis classes} \\ \midrule min patient cases & \multicolumn{2}{c}{wife precision} & \multicolumn{2}{c}{husband precision} & \multicolumn{2}{c}{couple precision} & \\ 300 & \multicolumn{2}{c}{0.0589} & \multicolumn{2}{c}{0.0500} & \multicolumn{2}{c}{0.0626} & \\ 500 & \multicolumn{2}{c}{0.0572} & \multicolumn{2}{c}{0.0481} & \multicolumn{2}{c}{0.0624} & \\ \bottomrule \end{tabular} \captionsetup{font=small}\caption*{ Notes: In the table, FPR1 denotes FPR where the label is abnormal birth and the diagnosis is wife being high risk; FPR2 and FPR3 are similarly defined for the diagnosis classes of husband being high risk and both spouses being high risk. Similarly for TPR1, TPR2 and TPR3. } \end{table} On the one hand, in Panels A and B of Table (ref), there are some differences between the TPRs and FPRs among the three diagnosing classes of high risk wife, husband and both spouses. However, without the corresponding outcome level it is difficult to interpret these ratios since the total number of abnormal births used in calculating the denominators aggregates the three unobserved latent outcome labels corresponding to high risk wife, husband and both spouses. On the other hand, Panel C of Table (ref) reports the precision for each of the three diagnosis classes (high risk wife, husband and couple). Precision is defined as the fraction of abnormal birth for each of the diagnosis classes. For example, wife (husband) precision represents the fraction of couples with a high risk wife (husband) diagnosis who have an abnormal birth outcome. Couple precision is similarly defined. In Panel C of Table (ref), the precision parameters for different diagnosis classes are close to each other. The precision parameters, despite being an imperfect measurement, provide a more accurate indication suggesting that the relative costs of false positives to false negatives are not different between cases when a single person is deemed risky and when both are. \begin{comment} The precision parameter, despite being an imperfect measurement, provides a more accurate indication of whether the relative costs of false positives to false negatives are constant for cases when a single person is deemed risky as when both are. The precision parameters reported in Panel C of Table (ref) for different diagnosis classes are close to each other, indicating constant relative costs of false positives to false negatives for cases when a single person is deemed risky and when both are. \end{comment} \begin{comment} \begin{table}[h!] \caption{Precisions across diagnosis classes: precision1 denotes precision where the label is abnormal birth and the diagnosis is wife being high risk; precision2 and precision3 are similarly defined for the diagnosis classes of husband being high risk and both spouses being high risk. } \begin{tabular}{cccc} \toprule min_patient_cases & wife precision & husband precision & couple precision \\ \midrule 300 & 0.0589 & 0.0500 & 0.0626 \\ 500 & 0.0572 & 0.0481 & 0.0624 \\ \bottomrule \end{tabular} \end{table} \end{comment}

Empirical Results for AI and doctor decision making

This section presents the empirical results from the heuristic frequentist approach described in section (ref) and the Bayesian approach described in section (ref). Doctors who are not replaced by the machine algorithm are called retained doctors hereafter.

Results of the heuristic frequentist approach

The frequentist approach identifies a dominating segment of the machine ROC for machine algorithm classification. The quality of machine algorithm classification is evaluated by averaging over a uniform grid of points on this dominating segment. For each doctor, we obtain the 95% elliptical confidence area of $\theta_{H}$ centered around the sample estimates using an estimate of the asymptotic covariance matrix based on 100 bootstrap samples. We find the largest TPR point $\left(\alpha_{\beta_{high}}, \beta_{high}\right)$ and the smallest FPR point $\left(\alpha_{low}, \beta_{{low}}\right)$ of the confidence set. The reference point of the doctor is then given by $P = \left(\alpha_{low}, \beta_{high}\right)$, as shown in Figure (ref), which is used to classify doctors into two groups. When a doctor's reference point $P$ is below the machine ROC curve, corresponding to case 1 in section (ref), the doctor is replaced by the algorithm. When a doctor's reference point $P$ is above the machine ROC curve, corresponding to cases 2 or 3 in section (ref), either because this doctor is more capable than the algorithm or this doctor's capability cannot be precisely measured due to fewer patient observations and a larger confidence set, the doctor is retained in decision making.

Among the 584 doctors, 175 doctors are classified by the frequentist approach as replaced by the algorithm. Consequently, patient cases in the performance set are diagnosed by 175 machine doctors (30.0%) and 409 (70.0%) human doctors. For each of the replaced doctors, $N = 100$ points on the dominating segment of the machine ROC curve are chosen corresponding to a uniform grid of the threshold value $c$ for the algorithm to make classification decisions, as summarized in Appendix (ref). Figure (ref) shows the results of this experiment. The aggregate FPR/TPR pair of all doctors on the performance set, represented by the blue point, is 0.2065 for FPR and 0.2264 for TPR. The ROC curve of the random forest model on the performance set is the green curve. The area under the curve (AUC) is 0.6851.

The yellow point uses a decision threshold $c$ corresponding to the upper endpoint of the dominating segment of the machine ROC curve associated with a highest FPR/TPR pair of 0.2017 and 0.3326. Compared to the raw data where all diagnoses are performed by doctors, the yellow point increases the TPR by 46.9% and reduces the FPR by 2.3%. The green point corresponds to the lower endpoint of the dominating segment of the machine ROC curve and is associated with a lowest FPR/TPR pair of 0.1836 and 0.2974. Compared to the aggregate doctor diagnoses, the green point increases the TPR by 31.4% and reduces the FPR by 11.1%.

figure[figure omitted — 1,038 chars of source]

The cyan interval in Figure (ref) reflects a trade-off between improving the TPR and reducing the FPR. Any point along the interval represents an enhancement over the aggregated doctors' FPR/TPR pair. Furthermore, the red point achieves the maximum F1 score\footnote{The F1 score is the harmonic average of precision and recall, and is often used as a single measurement that conveys the balance between precision and recall. It is widely used in evaluating the performance of algorithms (see for example baeza1999modern).} of 0.1309 along the dominating segment of the machine ROC curve. Figure (ref) is a scatter plot of the FPR/TPR pairs of both replaced and retained doctors against the ROC curve in the performance dataset. We see that two adjacent points can be of different replacement status. This can be due to different numbers of patients treated or the use of the test set for calculating the FPR/TPR pairs. An important caveat is that our test depends crucially on the sample size of the number of patients treated by each doctor, which introduces an implicit bias that favors experimenting with junior doctors until the null hypothesis that a doctor is not to be replaced is rejected with sufficient evidence from seeing a large number of patient cases.

commentFor a robustness check, we conduct the experiment again based on the subsample of doctors who diagnosed more than 500 patients. Other settings of the algorithm implementation are kept the same. After classifying the performance of the doctors in the sample we find 135 less capable doctors among 367 doctors. In other words, 36.8% of doctors would be replaced by the algorithm and 63.2% of human doctors would be retained in the performance dataset.
figure[figure omitted — 717 chars of source]
commentThe lower left (green) point of the cyan interval achieves 0.1723 for the FPR and 0.2966 for the TPR. Compared to all doctor diagnoses, the mixture of the algorithm's decision rule and human decisions corresponding to this point obtains an improvement of 38.9% in the TPR and a reduction of 11.3% in the FPR. The point that achieves the maximum F1 score among the cyan curves is the red point in Figure (ref), which registered an F1 score of 0.1351. The overall performance of the combination of the algorithm with capable doctors does not differ substantially from the performance obtained in the previous experiments conducted with doctors diagnosing more than 300 patients, providing empirical evidence assuring the robustness of the experiment results.

When the quality of the stock of decision makers may evolve over time, allowing the juniors to learn from making potentially suboptimal decisions for their patients has the potential of increasing the future pool of high quality seniors. This is likely to be a very delicate issue involving complex welfare tradeoff between current and future generations of patients.

Results of the Bayesian approach

The prior distribution $\pi(t)$ is chosen to be a symmetry Dirichlet distribution with the parameters $\left(\gamma_1, \gamma_2, \gamma_3, \gamma_4\right)$ all set to $\gamma = 0.01$. For doctor $j$'s $i$th patient case, $\hat{Y}_{ij}$ is the doctor's diagnosis and $Y_{ij}$ is the ground-truth label of pregnancy outcome.

commentWe group each doctor's cases into four multinomial classes according to the values of $\hat{Y}$ and $Y$ of each case and calculate the frequency of each class; i.e.,\begin{enumerate} • $n\hat{t}_1$ equals the number of cases in which $Y=1, \hat{Y}=1$; • $n\hat{t}_2$ equals the number of cases in which $Y=0, \hat{Y}=1$; • $n\hat{t}_3$ equals the number of cases in which $Y=1, \hat{Y}=0$; • $n\hat{t}_4$ equals the number of cases in which $Y=0, \hat{Y}=0$. \end{enumerate}

The likelihood for data is given in (ref) where $\hat Y_i$, $Y_i$ and $n$ in (ref) are replaced by $\hat Y_{ij}$, $Y_{ij}$ and $n_j$. The posterior distribution is also a Dirichlet distribution with parameters $(\hat{\gamma}_1, \hat{\gamma}_2, \hat{\gamma}_3, \hat{\gamma}_4)$ where $\hat{\gamma}_{k} = \gamma + n\hat{t}_k$ for $k = 1, 2, 3, 4$. The posterior distribution of $\theta_{H} = (\alpha_{H}, \beta_{H})$ can be simulated in a two step procedure. In the first step, $R$ samples of $\{t_r = (t_{1r}, t_{2r}, t_{3r}, t_{4r})\}_{r = 1}^{R}$ are drawn from the posterior Dirichlet distribution with parameters $(\hat{\gamma}_1, \hat{\gamma}_2, \hat{\gamma}_3, \hat{\gamma}_4)$. In the second step, we compute $\{\theta_{H, r} = \left(\alpha_{H}\(t_{r}\right), \beta_{H}\(t_{r}\right)\right)\}_{r = 1}^{R}$ with the simulated $R$ samples of $t_r, r=1,\ldots,R$, using (ref).

The simulated draws $\theta_{H, r}, r=1,\ldots,R$ are used to calculate (ref). If $\hat{q}_{max} \geq 0.95$, we mark the doctor as replaced. The threshold $c$ that corresponds to the point $\left(\hat{\alpha}_{max}, g\left(\hat\alpha_{max}\right)\right)$ given by (ref) is used as the decision threshold for the algorithm.

commentDesignating a doctor as being replaced is to be understood in the Bayesian sense, i.e., that the posterior distribution of $\theta_{H}$ is dominated significantly by the machine ROC curve. Otherwise, the doctor will not be replaced by the algorithm. For example, Figure (ref) shows a case where a doctor will be replaced by the algorithm. The maximum coverage rate $q$ achieves 0.9657 at the black point on the machine ROC curve. However, in Figure (ref), the maximum coverage rate achieves only 0.3179, suggesting that there is not sufficient evidence to replace the doctor's decisions with the algorithm's decisions.

In Figure (ref), the maximum coverage rate $\hat q_{max} = 0.9657$ at the black point on the machine ROC curve. The doctor is replaced by the algorithm. In Figure (ref), the maximum coverage rate $\hat q_{max} = 0.3179$. There is not sufficient evidence to replace the doctor's decisions with the algorithm's.

figure[figure omitted — 1,175 chars of source]

Figure (ref) shows the experiment results for doctors who had diagnosed more than 300 cases. A total of 269 (46.1%) out of 584 doctors are classified as replaced. The remaining 315 (53.9%) are retained human doctors. The combined decisions by the retained human doctors and the algorithm's decisions indicated in the figure by the yellow point, result in an FPR of 0.1856 and a TPR of 0.3319, corresponding to an increase of 46.6% in the TPR and a reduction of 10.1% in the FPR.

commentFigure (ref) (ref) \subref{fg:ai-doctors-bayesian-500} shows the experiment results for only those doctors who diagnosed more than 500 cases. Among all 367 such doctors, 201 are classified as less capable doctors. Therefore, 166 (45.2%) human doctors and 201 (54.8%) machine doctors are involved in the evaluation on the performance dataset. By replacing the decisions made by less capable doctors with the algorithm's decisions, the aggregate FPR and TPR for combined decision making are 0.1783 and 0.3292, respectively. In other words, we obtain an improvement of 54.2% on the TPR and a reduction of 8.2% on the FPR.

Similar to Figure (ref), Figure (ref) is a scatter plot of the FPR/TPR pairs of both replaced and retained doctors against the ROC curve in the performance dataset.

figure[figure omitted — 1,048 chars of source]

We experiment with several alternative definitions described in equations (ref) to (ref) for the Bayesian posterior expected loss functions in (ref). These results are shown in Figure (ref), where panel \subref{fg:ai-doctors-bayesian-score-horizonal-lower-300} magnifies a portion of panel \subref{fg:ai-doctors-bayesian-score-horizonal-upper-300} containing the replacement paths. Ranking the doctors by their expected posterior losses allows us to replace only the doctors whose expected loss of being substituted by the machine algorithm is relatively low. Figure (ref) traces the dynamics of the aggregate FPR/TPR pairs of combining the doctor with the machine decisions, when the ratio of replaced doctors increases from 0% to 100%.

figure[figure omitted — 1,121 chars of source]

In Figure (ref) legends, {\it Bayesian Test} refers to the baseline construction in (ref); {\it Euclidean Distance to the ROC curve} refers to the loss function in (ref); {\it Complementary Set Boundary Euclidean Distance} refers to the loss function in (ref); {\it Diagonal Line Horizontal and Vertical Decompositions} refer to the loss function in (ref); {\it Complement Set Boundary Vertical and Horizontal Decompositions} refer to the loss function in (ref). No individual loss function demonstrates saliently stronger discriminatory power over the entire replacement path. Furthermore, the incremental benefit going beyond a 50% replacement rate is a small marginal reduction of FPR. In addition, the baseline 95% credible level Bayesian test implemented using (ref) is not dominated by any of the competing methods in the FPR/TPR comparison.

The null hypothesis of both the Bayesian analysis and the frequentist analysis is the status quo of human decision making. A human decision maker is replaced by the machine algorithm only when there is strong evidence from the data favoring the machine algorithm. An alternative conceptual paradigm is to treat the machine algorithm as the status quo null hypothesis, where the human decision makers are by default replaced by the machine algorithm unless there is strong data evidence validating the superiority of human decision making.

However, when we experiment with the alternative specification of the status quo, all except a few doctors are determined to be replaced by the machine algorithm. In the cross-point labeled as the “dominate method” in Figure (ref), a doctor is retained if there exists a point on the machine ROC curve that is dominated by at least 95% of the posterior distribution of $p\left(\theta_H \vert \mathbb{D}\right)$. A mere 6 doctors are retained in this method. In the cross-point labeled as the “above method” in Figure (ref), a doctor is retained if the posterior probability of $p\left(\theta_H \vert \mathbb{D}\right)$ above the machine ROC curve is more than 95%. Only 7 doctors are retained using this method. For doctors who are replaced by the machine algorithm, the replacement point on the ROC curve is determined by the baseline Bayesian tests in (ref).

figure[figure omitted — 1,331 chars of source]

At high replacement ratios, the FPR and TPR levels decrease simultaneously across all loss functions. Even when all the doctors are substituted by the machine algorithm, the resulting FPR/TPR pair still lies below the machine ROC curve. This is because different threshold cutoff values on the machine ROC curve are employed to replace different doctors and because of the concavity arguments formalized in Lemma (ref).

On the one hand, in the current empirical dataset, only a small fraction of doctors have FPR/TPR pairs above the machine ROC curve. We have not been able to combine doctors with the machine algorithm to generate a FPR/TPR pair above the machine ROC curve. On the other hand, using a data generating process that allows for a substantial portion of doctors with FPR/TPR pairs to be above machine ROC curve, reported in the synthetic data analysis section (ref), we are able to combine the doctors and the machine algorithm to generate a FPR/TPR pair that outperforms even the machine ROC curve.

Instead of deterministically replacing some doctors by the machine algorithm, Appendix (ref) reports the results of a randomized replacement experiment where each replaced doctor accepts the machine decision probabilistically according to a pre-specified acceptance rate $\lambda\in\left[0,1\right]$. As expected, the overall FPR/TPR pairs vary incrementally from when $\lambda=0$, corresponding to human decision making, to when $\lambda=1$, corresponding to deterministic replacement of doctors by the machine algorithm.

Appendix (ref) considers a more general form of substitution to replace a subset of patient cases for each doctor. We use patient case covariates to predict the likelihood that the doctor's diagnoses differ from the ground-truth outcome, and replace only those patient cases where the doctor is prone to make mistakes. While the resulting pattern of the replacement paths is quite different, the patient-case specific substitution approach does not show saliently stronger discriminatory power compared to the baseline Bayesian approach.

Characteristics of replaced doctors

Our paper identifies a subset of the doctors to be replaced by the machine algorithms according to FPR/TPR indicators. We create a dummy variable “replaced” that is set to 1 when a doctor is replaced by the algorithm and is set to 0 otherwise, and examine the partial correlation coefficient between the “replaced” dummy variable with several confounding factors including whether they practice in a clinic or hospital.

We regress the “replaced” indicator on three confounding factors. The first factor is county-level per capita GDP (in ten thousand Chinese yuans) collected manually from the statistical yearbooks of 2014 across cities and provinces, which is the starting year of our data\footnote{The statistical yearbook of year $A$ records the latest available data before year $A$.}. The second factor is the logarithm of the total number of patient cases diagnosed by each doctor. The third factor is represented by two dummy variables related to the practice history of each doctor. A doctor in our dataset may practice in more than one type of facility. The practice facility can be either a county hospital or a township clinic. Medical facilities in China are typically classified by the administrative level that they belong to. On the one hand, urban residents usually go to a county level hospital. On the other hand, rural residents often times go to a township level clinic, which is generally considered to be of lower quality than a county level hospital. The doctors in our data fall into three categories. Doctors who have practiced in both types of facilities are used as the reference level. The first dummy variable representing the third factor is set to $1$ for doctors who have practiced only in a county hospital. The second dummy variable representing the third factor is set to $1$ for doctors who have practiced only in a township clinic. There are additional variables in the dataset that are only available at a more aggregated the city or province level, such as birth rate and the average number of medical staff. We do not use these variables because, given how administrative units are divided in China, a municipal unit can include many county level units with heterogenuous economic conditions.

The data summary statistics are reported in Panel A of Table (ref). As shown in Panel A of Table (ref), doctors who have practiced at both a county hospital and a township clinic have seen the largest number of patient cases and have a high replacement ratio. Doctors who have practiced only at a township clinic have seen a smaller number of patient cases compared to doctors who have practiced only at a county hospital, but doctors who have practiced only at a township clinic have a higher replacement ratio than doctors who have practiced only at a county hospital have.

comment\begin{table}[htbp] \caption{Summary statistics by plan type} \begin{tabular}{lrrrr} \toprule & num & log_mean & gdp_mean & replace_ratio \\ \midrule both & 276 & 6.79701 & 3.95602 & 0.521739 \\ & & (0.72858) & (2.94475) & \\ county_only & 161 & 6.51534 & 3.67451 & 0.397516 \\ & & (0.645367) & (2.26868) & \\ \textbf{town_only} & 43 & 6.40894 & 3.87014 & 0.511628 \\ & & (0.581616) & (2.25751) & \\ \bottomrule \multicolumn{5}{l}{ Standard deviations are in parentheses.}\\ \end{tabular} \end{table}
table[table omitted — 1,987 chars of source]
commentTable (ref) reports the results of a logistic regression of the “less capable” dummy variable on the "township” dummy variable and the confounding factors that are being controlled for, using the classification from the baseline Bayesian test approach for all doctors who diagnosed more than 300 patient cases. Doctors with missing data are excluded from the regression\footnote{In order to correct for spatial autocorrelation that may occur in the regressions, we use the cluster (by city where the doctors are located) robust standard error.}. Relative to doctors from urban clinics, doctors from rural clinics have a saliently higher (by 16.2%) probability of being replaced by the algorithm. In particular, in the context of the baseline Bayesian test results, 53.3% of 319 doctors from rural clinics are replaced by the algorithm, while only 37.1% of 244 urban clinic doctors are replaced. In the logistic regressions, the estimated coefficient of the township dummy is statistically significant and positive, see Table (ref). \begin{sidewaystable}[htbp] \caption{Replaced Doctors and Geographic Characteristics} \begin{tabular}{l*{9}{c}} \toprule & \multicolumn{1}{c}{(1)} & \multicolumn{1}{c}{(2)} & \multicolumn{1}{c}{(3)} & \multicolumn{1}{c}{(4)} & \multicolumn{1}{c}{(5)} & \multicolumn{1}{c}{(6)} & \multicolumn{1}{c}{(7)} & \multicolumn{1}{c}{(8)} & \multicolumn{1}{c}{(9)} \\ \midrule GDP per capita & & 0.00872 & 0.0249 & 0.0242 & 0.0257 & 0.00622 & \\ & & (0.59) & (1.45) & (1.41) & (1.69) & (0.42) & \\ Medical staff per capita & & & -0.00704 & -0.00707 & -0.00598 & & -0.00640 & \\ & & & (-2.19) & (-2.37) & (-2.37) & & (-2.03) &\\ Birth rate & & & & 37.917 & 31.679 & & & 31.215 &\\ & & & & (1.47) & (1.11) & & & (1.21) &\\ Log patient number & & & & & 0.767 & & & & 0.841 \\ & & & & & (5.43) & & & & (6.01)\\ Township indicator & 0.662 & 0.666 & 0.636 & 0.646 & 0.483 & \\ & (4.12) & (4.13) & (3.86) & (3.87) & (2.86) & \\ \addlinespace Constant & -0.528 & -0.570 & -0.230 & -0.731 & -5.722 & -0.173 & 0.217 & -0.558 & -5.736\\ & (-4.52) & (-4.03) & (-1.10) & (-1.83) & (-5.44) & (-1.61) & (1.19) & (-1.57) & (-6.25)\\ \midrule Observations & 498 & 498 & 498 & 498 & 498 & 498 & 498 & 498 & 498 \\ \bottomrule \multicolumn{7}{l}{ z statistics in parentheses} \end{tabular} \end{sidewaystable}

Panel B in Table (ref) reports a logistic regression of the replacement indicator on county level per capita GDP and the logarithm of the number of patients seen by the doctor. Column (2) adds an indicator of whether the doctor practices only in a township clinic, and an indicator of whether the doctor practices only in a county hospital. The reference level where both indicators are zero corresponds to doctors who have practiced in both a township clinic and a county hospital. Province fixed effects are included in the logistic regression. We use cluster robust standard errors in order to correct for spatial autocorrelation.

comment\begin{table}[htbp] \caption{Logistic regression with province fixed effect} \begin{tabular}{l*{2}{cc}} \hline\hline &\multicolumn{1}{c}{(2)}& &\multicolumn{1}{c}{(5)}& \\ & b/t& ci95& b/t& ci95\\ \hline log_total & 0.925& 0.324,1.526& 0.907& 0.362,1.451\\ & (3.017)& & (3.264)& \\ gdp_pcow & -0.00154&-0.0582,0.0551& -0.00376&-0.0586,0.0511\\ & (-0.0533)& & (-0.134)& \\ countyplan_only & & & -0.377&-0.726,-0.0279\\ & & & (-2.117)& \\ townplan_only & & & 0.247&-0.301,0.794\\ & & & (0.883)& \\ \hline Observations & 470& & 470& \\ \hline \multicolumn{5}{l}{ z statistics in parentheses}\\ \end{tabular} \end{table}
comment\begin{table}[htbp] \caption{Logistic regression with province fixed effect} \begin{tabular}{l*{2}{cc}} \hline\hline &\multicolumn{1}{c}{(2)}& &\multicolumn{1}{c}{(5)}& \\ & b/t& ci95& b/t& ci95\\ \hline log_total & 0.896& 0.281,1.511 & 0.885& 0.343, 1.428\\ & (2.853)& & (3.199)& \\ gdp_pcow & -0.0114&-0.0715,0.0486 & -0.0124&-0.0721, 0.0472\\ & (-0.373) & & (-0.408)& \\ countyplan_only & & & -0.367&-0.729,-0.00561\\ & & & (-1.990)& \\ townplan_only & & & 0.359&-0.457,1.175\\ & & & (0.863)& \\ \hline Observations & 457& & 457& \\ \hline \multicolumn{5}{l}{ z statistics in parentheses}\\ \end{tabular} \end{table}

The logistic coefficient estimates do not contradict our a priori reasoning. While higher per capita GDP is associated with a lower likelihood of replacement, the corresponding coefficients are small and lack statistical significance. The coefficients of the log number of patients are positive and statistically significant, indicating the higher distinguishing power of the Bayesian test when a doctor sees more patients. The FPR/TPR pairs of doctors with more patient cases can be estimated more precisely. Consequently, it is more likely for these doctors whose FPR/TPR pairs are below the machine ROC curve to be identified as replaced by our statistical procedure. This finding is consistent with the lack of evidence contradicting Assumption (ref) that doctors accumulate experience from additional patient cases.

Doctors practicing only at township clinics have higher replacement probability than reference level doctors practicing at both township clinics and county hospitals, who in turn have higher replacement probability than doctors practicing only at county hospitals. Anecdotal evidence in China suggests that doctors with better medical school records are more likely to be assigned directly to county level hospitals than to have to work their ways up from township clinics into county hospitals.

To distinguish an analysis of the predictors of performance of doctors from the predictors of tests concluding whether they are to be replaced by the machine algorithm, we implement a kernel regression of TPR on FPR and a number of confounding features including county level per capita GDP, the logarithm of the number of patients seen by the doctor, an indicator of whether the doctor practices only in a township clinic, and an indicator of whether the doctor practices only in a county hospital.\footnote{We thank the associate editor and the review team for suggesting a direct analysis of the performance of doctors.} Among doctors achieving the same FPR, those achieving a higher TPR can be considered to perform better. A confounding variable with a positive coefficient enhances the TPR after controlling for FPR, and is interpreted as a variable that positively predicts performance.

Panel C in Table (ref) reports the results from this regression. The regression coefficients have signs that are consistent with a priori reasoning, but they are also mostly insignificant except for the coefficients on the indicator of whether the doctor practices only in a county hospital. For a given FPR, a higher TPR is positively associated with higher county level per capita GDP, a larger number of patients seen by the doctor and the indicator that the doctor practices only in a county hospital, but is negatively associated with the indicator that the doctor practices only in a township clinic.

comment\begin{table}[htbp] \caption{TPR kernel regression} \begin{tabular}{l*{2}{cc}} \hline\hline & \multicolumn{1}{c}{(3)}& &\multicolumn{1}{c}{(4)}& \\ & b/t& ci95& b/t& ci95\\ \hline fpr & 0.970& 0.924,1.016& 0.960& 0.915,1.006\\ & (41.59)& & (41.04)& \\ log_total & 0.00362&-0.00915,0.0164& 0.00128&-0.0109,0.0135\\ & (0.555)& & (0.205)& \\ r1vs0.countyplan_only& 0.0173&0.00149,0.0332& 0.0202&0.00152,0.0388\\ & (2.144)& & (2.120)& \\ r1vs0.townplan_only & -0.0152&-0.0453,0.0149& -0.00872&-0.0375,0.0201\\ & (-0.989)& & (-0.594)& \\ gdp_pcow & & & 0.00209&-0.00221,0.00638\\ & & & (0.952)& \\ \hline Observations & 484& & 482& \\ \hline\hline \multicolumn{5}{l}{ t statistics in parentheses}\\ \end{tabular} \end{table}

The statistical insignificance of the coefficients on the logarithm of the number of treated patients in Panel C of Table (ref) and their significance in Panel B of Table (ref) provide further evidence that the replacement indicator is largely driven by the difference in the sample size. A larger sample size makes it easier to reject the null hypothesis that the machine algorithm does not outperform the doctor.

commentOverall, these regression results indicate that artificial intelligence technology assisted decision making has a tendency to improve precision in rural areas more than in developed cities. The statistical association revealed by the empirical data analysis has an intuitive appeal: doctors in economically disadvantaged areas are likely to have received less advanced training in sophisticated medical skills, and to be equipped with insufficient frontier knowledge in making quality diagnostic decisions. An important implication of our empirical analysis is the potential of employing artificial intelligence technology in designing poverty-related economic policies to improve the welfare of impoverished areas. These empirical findings are also reinforced by the observation that the coefficients on the township dummy and their statistical significance are stable across different columns of Table (ref) and robust against the inclusion of additional confounders. Our empirical results provide yet another example to strengthen the conjecture that AI might help poor areas more, adding to a variety of conferences and papers studying AI for poorer areas that show similar results. See for example \url{https://www.md4sg.com} and \url{https://sites.google.com/view/ml4d}\footnote{We are grateful to both anonymous referees for referring us to the literature and for interpreting the empirical findings.}. Ultimately, a broad AI-based system needs to be deployed and evaluated in order to validate these scientific conjectures and speculations.
comment\begin{table}[htbp] \caption{Replaced Doctors and Geographic Characteristics} \begin{tabular}{l*{6}{c}} \toprule \multicolumn{7}{l}{Panel A: Bayesian Approach} \\ \midrule &\multicolumn{1}{c}{(1)}&\multicolumn{1}{c}{(2)}&\multicolumn{1}{c}{(3)}&\multicolumn{1}{c}{(4)}&\multicolumn{1}{c}{(5)}&\multicolumn{1}{c}{(6)}\\ &\multicolumn{1}{c}{OLS}&\multicolumn{1}{c}{OLS}&\multicolumn{1}{c}{OLS}&\multicolumn{1}{c}{Logit}&\multicolumn{1}{c}{Logit}&\multicolumn{1}{c}{Logit}\\ \midrule gdp_all_province & -0.0971& & -0.0773& -0.393& & -0.317\\ & (-0.74)& & (-0.59)& (-0.74)& & (-0.59)\\ township indicator & & 0.103& 0.101& & 0.417& 0.411\\ & & (2.44)& (2.40)& & (2.43)& (2.39)\\ \addlinespace Constant & 0.490& 0.402& 0.427& -0.0373& -0.399& -0.296\\ & (10.59)& (12.63)& (8.02)& (-0.20)& (-3.05)& (-1.37)\\ \midrule Observations & 563& 563& 563& 563& 563& 563\\ $R^{2}$ & 0.001& 0.011& 0.011& & & \\ \toprule \multicolumn{7}{l}{Panel B: Frequentist Approach} \\ \midrule &\multicolumn{1}{c}{(1)}&\multicolumn{1}{c}{(2)}&\multicolumn{1}{c}{(3)}&\multicolumn{1}{c}{(4)}&\multicolumn{1}{c}{(5)}&\multicolumn{1}{c}{(6)}\\ &\multicolumn{1}{c}{OLS}&\multicolumn{1}{c}{OLS}&\multicolumn{1}{c}{OLS}&\multicolumn{1}{c}{Logit}&\multicolumn{1}{c}{Logit}&\multicolumn{1}{c}{Logit}\\ \midrule gdp_all_province & -0.184& & -0.164& -0.752& & -0.678\\ & (-1.40)& & (-1.25)& (-1.40)& & (-1.25)\\ \addlinespace township=1 & & 0.108& 0.105& & 0.439& 0.427\\ & & (2.56)& (2.48)& & (2.55)& (2.47)\\ \addlinespace Constant & 0.513& 0.393& 0.447& 0.0533& -0.433& -0.214\\ & (11.09)& (12.39)& (8.41)& (0.28)& (-3.30)& (-0.98)\\ \midrule Observations & 563& 563& 563& 563& 563& 563\\ $R^{2}$ & 0.004& 0.012& 0.014& & & \\ \bottomrule \multicolumn{7}{l}{ t statistics in parentheses}\\ \end{tabular} \end{table}

Synthetic Data Analysis

An example of human-algorithm complementarity

In our empirical dataset, only a small fraction of doctors lie above the machine ROC curve. Combining the machine algorithm and the doctor decisions results in aggregate FPR/TPR pairs that are still below the machine ROC curve. In addition, Jensen's inequality (elaborated in section (ref)) likely contributes to the combined aggregate FPR/TPR pair lying below the machine ROC curve. Even if we replace every doctor by the machine algorithm, unless the same point on the machine ROC curve is used to replace all doctors, the combined aggregate FPR/TPR pair is necessarily below the machine ROC curve. The end points of the replacement paths in Figure (ref) correspond to replacing all doctors by the machine algorithm. The algorithms that we implemented use different points on the machine ROC curve to replace doctors. These points also differ across different doctors. In order for the combined aggregate FPR/TPR pair to be above the machine ROC curve, it is necessary that a sizable portion of the original doctor diagnoses lie above the machine ROC curve.

While not the case in the NFPC dataset, other datasets might exist where a significant portion of human decision makers correctly use private information not available to the machine algorithm. Figure (ref) reports the results from a synthetic data analysis where the combined aggregate FPR/TPR pair between doctors and the machine algorithm lies above the machine ROC curve.

figure[figure omitted — 940 chars of source]

The data generating process of the simulation in Figure (ref) is as follows. The input features are three dimensional: $x_{i,j,1}$, $x_{i,j,2}$ and $u_{i,j}$. On the one hand, the first two features, denoted $x_{i,j,1}$ and $x_{i,j,2}$, are assumed to be observable both by the doctors and the machine algorithm. On the other hand, the last feature, denoted $u_{i,j}$, is only observable to the doctors and is not used by the machine algorithm. The three features are generated from independent normal distributions with pre-specified means and variances: $X_{i,j,1}\sim N\left(0,1.95\right)$, $X_{i,j,2} \sim N\left(0,0.25\right)$ and $U_{i,j} \sim N\left(0,2\right)$. The ground truth variable $Y_{i,j} \in\{0,1\}$ is generated by

align[align omitted — 275 chars of source]

and where $\delta_{i,j}$ is uniformly distributed between $0$ and $1$. Using this specification of the data generating process, we simulated 600,000 patient cases and allocate them evenly to 2000 doctors. Each doctor is assigned 300 simulated patient cases.

Doctors are partitioned into two groups according to their information processing capacities. The first group, consisting of 750 {\it more capable} doctors, use the correct full information propensity score $p\(x_{i,j,1}, x_{i,j,2}, u_{i,j}\right)$ with different incentives to diagnose patient cases. Their decision rule is given by, using $C_j$ that is uniformly distributed between $0.4$ and $1$ across doctors,

align[align omitted — 126 chars of source]

The second group of doctors, consisting of 1250 {\it less capable} doctors, use a misspecified propensity score to diagnose patients. Their decision rule is

align[align omitted — 270 chars of source]

is a misspecified propensity score function.

We divide the 600,000 simulated observations into a training subset consisting of 240,000 observations, a validation subset consisting of 180,000 observations and a test subset consisting of the remaining 180,000 observations. We estimate a random forest model using only the training subset and the first two features $x_{i,j,1}$ and $x_{i,j,2}$, and use the baseline Bayesian test in equation (ref) to combine doctors with the machine algorithm. The red point in Figure (ref) represents the combination of doctors and the machine algorithm. It lies above the ROC curve of the random forest model, and also strictly dominates the blue point of the aggregate FPR/TPR pair of all doctors. In summary, the synthetic data analysis represented by Figure (ref) illustrates the scientific principle of complementarity in human algorithm collaborations. See for example bansal2021does.\footnote{ We are grateful to an anonymous referee for pointing us to the science literature on human-algorithm collaboration complementary.}

Aggregating information by predicted doctor models

Our dataset contains doctor diagnoses information in addition to the eventual pregnancy outcomes. In this section we discuss whether estimating a model that predicts the label of doctors' diagnoses can assist in improving the FPR/TPR tradeoff of medical decisions. A model of predicted doctors can be intuitively interpreted as doctors' collective wisdom. The experience of senior doctors can provide guidance to junior doctors with limited clinical exposures.

In the NFPC dataset, a model of predicted doctors does not appear to improve on the aggregate FPR/TPR pair. However, in several of the following synthetic data examples, a predicted doctor model improves upon the diagnoses of individual doctors. Each doctors' diagnosis may encode information heterogeneity, or incentive heterogeneity, or both. Consider a model of incentive heterogeneity, where doctors' decision rules are given by $\hat y_{i} = \mathds{1}\(p\(x_{i}\right) > u_{i}\right)$ such that $p\(x_{i}\right)$ is the correctly specified propensity score, and $u_i$ is independently distribution with a strictly monotonic CDF $G\left(\cdot\right)$. On the one hand, the aggregate doctor FPR/TPR lies below the optimal ROC curve. On the other hand, the predicted doctor model, given by $\mathbb{E}\left[\mathds{1}\(p\(X_i\right) > U_i\right) \vert X_i\right] = \mathbb{P}\(U_i \leq p\(X_i\right)\right) = G\(p\(X_i\right)\right)$, is a monotonic transformation of the true propensity score function and recovers the optimal ROC curve.

We next focus on several information model without incentive heterogeneity. Consider a baseline example where doctors have access to private information $u_i$ in addition to the publicly observed features $x_i$ and are aware of the correct full information propensity score model $p\(x_i, u_i\right)$. If we could directly observe doctors' probabilistic assessment $p\(x_i, u_i\right)$ and use it as the label to train a machine learning model, then the resulting model will necessarily coincide with the ground-truth machine learned propensity score model:

align[align omitted — 223 chars of source]

However, in reality we rarely solicit doctors' probabilistic assessment of the likelihood of an illness. Instead, we only observe the binary diagnosis by the doctors, which corresponds to observing $\hat y_i=\mathds{1}\(p\(x_i, u_i\right) > c_0\right)$ for some threshold value $c_0$. When we use $\hat y_i$ as the label to train a machine learning model, the propensity score of the resulting predicted doctor model is

align[align omitted — 139 chars of source]

In general, $q\(X_i\right)$ is different from $p\(X_i\right)$. The ROC curve implied by $q\(X_i\right)$ coincides with $p\(X_i\right)$ only when $q\(X_i\right)$ is an increasing transformation of $p\(X_i\right)$: $q\(X_i\right)=\Lambda\(p\(X_i\right)\right)$, where $\Lambda\left(\cdot\right)$ is a strictly increasing function. There is no guarantee that this is necessarily the case.

Consider now three scenarios in which doctors employ misspecified models to process private information. In the first scenario, doctors process the full information $\(X_i, U_i\right)$ using an incorrect propensity score model $q\(X_i, U_i\right)$, but the ROC curve implied by the predicted doctor model $q\(X_i\right)$ still coincides with the ground-truth machine ROC curve. Figure (ref) illustrates this scenario using the following data generating process. The ground-truth propensity score model is $p\(X_{i}\right)=\exp\(X_{i}\right) / \left(1+\exp\(X_{i}\right)\right)$. The doctors use a misspecified propensity model of $q\(X_{i},U_{i}\right)=\exp\(X_{i}+U_{i}\right) / \left(1+\exp\(X_{i}+U_{i}\right)\right)$. Both $X_i$ and $U_i$ are uniformly and independently distributed: $X_{i} \sim U\left(-1, 1\right)$ and $U_{i} \sim U\left(-2, 2\right)$. The “$X_i$ only” ROC curve is generated by $p\(X_{i}\right)$; the “$X_i$ and $U_i$” ROC curve is generated by $q\(X_{i},U_{i}\right)$. The “Predicted Doctors on $X$” ROC curve is generated by $q\(X_i\right) \equiv \mathbb{E} \left[\mathds{1}\(q\(X_i, U_i\right) > c_0\right) \vert X_{i}\right].$

figure[figure omitted — 1,636 chars of source]

For any given cutoff threshold $c_0$, the predicted doctor model $q\(X_i\right)$ is an increasing function of $X_i$, as is $p\(X_i\right)$. In this particular case, both $p\(X_i\right)$ and $q\(X_i\right)$ correspond to the same ROC curve. This curve lies above the ROC curve generated by $q\(X_i, U_i\right)$ and the aggregate doctor FPR/TPR pair ($c_0=0.7$). Collective wisdom improves upon the misspecified model employed by individual doctors and results in higher diagnosing quality as represented by the ROC curves.

The second scenario, pictured in Figure (ref), is generated by a two dimensional observable feature model. The ground-truth propensity score model is

align[align omitted — 139 chars of source]

The doctors' (misspecified) information model is

align[align omitted — 157 chars of source]

$X_{i1}, X_{i2}$ and $U_i$ are independently distributed: $X_{i1} \sim N\left(0, 1\right), X_{i2} \sim N\left(0, 0.5\right), U_{i} \sim N\left(0,4\right)$.

In this scenario, doctors also process the full information $\(X_{i1}, X_{i2}, U_i\right)$ using an incorrect propensity score model. While the ROC curve corresponding to the predicted doctor model $q\(X_{i1}, X_{i2}\right)\equiv \mathbb{E} \left[\mathds{1}\(q\(X_{i1}, X_{i2}, U_i\right) > c_0\right) \vert X_{i1}, X_{i2}\right]$ lies below the optimal ROC curve corresponding to the correct propensity score model $p\(X_{i1},X_{i2}\right)$, it still lies above the ROC curve corresponding to the individual doctor misspecified information model $q\(X_{i1},X_{i2},U_{i}\right)$ and the aggregate doctor FPR/TPR pair. Collective wisdom in this case leads to limited improvement over the misspecified information model.

The third scenario is pictured in Figure (ref). The ground-truth propensity score model is $p\(X_{i}\right)=\exp\(X_{i}\right)/\left(1+\exp\(X_{i}\right)\right)$ but the doctors' incorrect information model is

align[align omitted — 143 chars of source]

where $X_{i}$ and $U_{i}$ are distributed as in the first scenario depicted in Figure (ref). In this model, doctors' information processing capacity is very limited. The predicted doctor model $q\(X_i\right) = \mathbb{E}\left[\mathds{1}\(p\(X_i, U_i\right) > c_0\right) \vert X_i\right]$ exacerbates the misspecification of the doctors' private information propensity score model, and leads to a ROC curve that lies strictly below the ROC curve corresponding to the individual doctor misspecified propensity score model $q\(X_{i},U_{i}\right)$.

The analysis in Figure (ref) shows that depending on the extent of misspecification of the doctors' information model, the predicted doctor model that aggregates the information among doctors using the subset of observable features available to the machine learning algorithm might either reduce or exacerbate the misspecification in the propensity score model. The resulting ROC curve of the predicted doctor model might lie above or below the ROC curve of the doctors' information model.

Replacement strategies initiated by doctors

commentEven though our experiment have shown that the fine-grained replacement approach fail to outperform the Bayesian approach, in real-life scenarios, doctors may still favor the fine-grained replacement method. What's more, instead of giving a global replace rate, with a fine-grained replacement approach doctors can choose when to use model prediction and when to use their own diagnosis. This enhancement may bring about a significant performance improvement which outperforms our Bayesian approach; However, it can also result in a disastrous performance drop if the doctors have no idea about under what condition they will make wrong decisions. We build up a simulation to show these circumstances. In this simulation, a doctor will not only give diagnosis on all patients, but also decide whether the diagnosis should be replaced by predictions from an imperfect machine. There are totally 30,000 patients in the simulation which are divided into training, validation and test dataset by a ration of 4:3:3. Every patient have three randomly generated features: $x_1$, $x_2$ and $u$. $x_1$ is sampled from $\mathcal{N}(0, 0.5)$, $x_2 ~ \mathcal{N}(0, 1.5)$, and $u ~ \mathcal{N}(0, 1)$. The ground truth $Y$ is decided by: \begin{equation*} \begin{aligned} Y = \mathds{1}\left(e^{x_1 + x_2 + u} / \left(1 + e^{x_1 + x_2 + u}\right) > c\right), \end{aligned} \end{equation*} where $c$ is a random variable chosen from $\rm{U}(0, 1)$. After generating 30,000 patients, we set up two different decision rules for doctor diagnosis. Briefly speaking, doctor diagnosis $\hat{Y}$ is simulated by \textcolor{red}{(plz check the notation and symbols I'm not sure about that)} \begin{equation*} \hat{Y} = \begin{cases} \mathds{1}\left(e^{x_1 + x_2 + u} / \left(1 + e^{x_1 + x_2 + u}\right) > c_d\right)& if \ x_1 \ge 0, \\ r > c_d & otherwise, \end{cases} \end{equation*} where $r$ is another random variable sampled from $\rm{U}(0, 1)$, and $c_d$ is the threshold for doctor diagnosis. These rules suggests that doctors can make good prediction under some circumstances, but sometimes they fail to figure out whether their patients are positive. Then, we trained a random forest model as the "machine" in this simulation. All the training parameters are kept the same with previous experiments. However, the model is only trained with $x_1$ and $x_2$, which indicates that the model is imperfect and cannot capture all features on the patients. \textcolor{red}{(or we cannot record/ doctors are so smart, I'm not sure which statement is official)} At last, we simulated four different replacement rules the doctor may give and show the result in Figure (ref). In Figure (ref), the doctor knows when they perform bad \textcolor{red}{(The number of this paragraph is weird as we have only one doctor but I cannot afford to use him/her due to PC reasons so plz check this)} and replace their diagnosis with machine predictions when $x_1 \ge 0$. As a result, the outcome of this method is even better than Bayesian approach, which will make replacement on all patients. In Figure (ref), the rule changes to $x_1 \ge 0.5$, which means the doctor know when they will make wrong decisions, but not so sure. Consequently, the performance is improved but does not outperform Bayesian approach. Figure (ref) use a replacement rule of $x_2 \le -0.5$. In this case, the doctor does not know when they perform bad and the replacement reduce both FPR and TPR. Figure (ref) shows a worst case, where doctor misunderstands themselves and gives a totally wrong replacement rule $x_1 \le 0$. The replacement result is even worse than the original doctor diagnosis.\textcolor{red}{TODO:Replace the funny subfigure titles} \begin{figure} \subfigure[Doctors know themselves well] \subfigure[Doctors know themselves] \subfigure[Doctors don't know themselves] \subfigure[Doctors know themselves so bad] \caption{Fine-Grained Replacement Results under Different Synthetic Doctor Settings} \end{figure}

For a given decision maker, recognizing that machine algorithms are more likely to be applicable in some candidate cases than in others is important for a replacement model to achieve human and machine complementarity. Formalizing such a general empirical replacement model is difficult because of the unknown diagnosing model employed by doctors in the data and because of our lack of knowledge of doctors' preferences for the machine algorithm. To illustrate these difficulties, we experiment with a set of simulations in which doctors decide when to employ machine learning algorithm.

In the simulation setup, each patient is associated with three independently generated normally distributed features $X_1, X_2, U$, where $X_1 \sim N(0, 0.5)$, $X_2 \sim N(0, 1.5)$ and $U \sim N(0, 1)$. The probability of each patient being ill is a logit function of the features:

align[align omitted — 121 chars of source]

The labels are generated according to the probability model $p\(X_1, X_2, U\right)$ for 30,000 patient cases. The diagnosis of doctors is modeled as a mixture between two decision rules. The first rule employs the correct probability model $p\(X_1, X_2, U\right)$. The second rule replaces the probability model $p\(x\right)$ by an uninformative uniformly distributed random variable $r \sim U\left(0,1\right)$. The second rule applies to a situation where the occasional lack of medical knowledge by doctors results in randomized diagnosis. Specifically, we simulate doctor diagnosis $\hat Y$ by

align[align omitted — 220 chars of source]

In the above, $c_d = 0.5$ is the decision threshold for doctor diagnosis. The simulated dataset is divided into training, validation and test subsets by the ratio of 4:3:3. They are used to estimate model parameters, compute the ROC curve and calculate FPR/TPR pairs respectively. We first train a random forest model using features $X_1$ and $X_2$, where $U$ is interpreted as unobserved heterogeneity that is known to the doctors but not to the machine algorithm.

figure[figure omitted — 1,371 chars of source]

We simulate four replacement rules. They are illustrated in Figure (ref). In the first rule, shown in Figure (ref), doctors know when their medical knowledge is inadequate (e.g. when $X_1 < 0$) and choose to defer to the machine algorithm in such a situation. This method achieves complementarity between the human doctor and the machine algorithm. It produces a FPR/TPR pair that is better than the Bayesian approach in wich either all or none of the patients for each doctor are replaced. In the second rule, shown in Figure (ref), doctors have partial but incomplete knowledge of when their medical knowledge is inadequate. Doctors defer to the machine algorithm when $X_1 < 0.5$. The second rule improves over the doctors, but does not outperform the Bayesian approach. Figure (ref) use a replacement rule of $X_2 \le -0.5$. In this case, the doctor does not know when they lack medical knowledge and the replacement reduces both FPR and TPR. In Figure (ref), doctors mistakenly defer to the machine algorithm when they do have medical knowledge (e.g. when $X_1 \geq 0$), but make their own decision when they are uninformed (e.g. when $X_1 < 0$). The resulting FPR/TPR pair is strictly dominated by the original doctor diagnosis.

Conclusion

In this paper, we propose statistical tests for replacing human decision makers with algorithms. Decision rules that robustly dominate diagnoses made by humans can be determined based on the machine ROC curves. We propose both a heuristic frequentist approach and an alternative Bayesian posterior loss function approaches. By replacing a subset of decision makers with algorithms, we can achieve higher quality decision making outcome. We experiment with the two approaches using a dataset of pre-pregnancy checkups, and find that the replacement of a subset of doctors using the Bayesian approach significantly improves the overall performance of risky pregnancy detection. Furthermore, our results indicate that doctors who practice only at township clinics are more likely to be replaced, while doctors who practice only at county hospitals are less likely to be replaced.

Our analysis shows that both stable preference and decision-making quality are important for comparing machine algorithm with human decision makers. While allowing the juniors to make potentially suboptimal decisions for their patients and learn from the results has the potential of increasing the pool of high quality seniors, this is a very delicate issue involving complex welfare tradeoff between current and future generations of patients. In panel datasets with rich dynamic information, human decision makers can engage in information updating and peer learning. Our current dataset is only cross-sectional. The eventual pregnancy outcomes are typically not available to doctors when they diagnose consecutive patient cases. Juniors might also benefit more generally from offline learning without having to make substantial and high stake decisions.

Acknowledgments

We thank the editors and two anonymous referees, Brendan Beare, Bo Honore, Xiaohong Chen, Ron Gallant, Bruce Hansen, Peter Hansen, Bentley MacLeod, Jack Porter, Adam Rosen, Andres Santos, George Tauchen, Valentin Verdier, and participants at various seminars and conferences for insightful comments. We also thank Yichuan Zhang, Xin Lin and Zhonghao Huang for excellent research assistance. This study was approved by the National Health Commission. Informed consents were obtained from all the NFPC participants. We acknowledge funding support from the National Science Foundation (SES 1658950 to Han Hong), the National Science Fund for Distinguished Young Scholars of China (71325007 to Ke Tang), the State’s Key Project of Research and Development Plan (2016YFC1000307 to Jingyuan Wang) and the National Natural Science Foundation of China (61572059 to Jingyuan Wang).

\FloatBarrier \phantomsection \addcontentsline{toc}{section}{References} { \setstretch{0.875} }

\processdelayedfloats