# d' Calculator

### An interactive tool for learning about signal detection theory

This webpage was designed to help students in PSYCH 30, a large undergradate class on Perception at Stanford University, understand the basics of Signal Detection Theory and the sensitivity index, d'. Play with the calculator below and scroll down to read more about signal detection and how to compute d'. If you have any issues or find bugs, please let me know via email!

#### ROC Curve

Signal Present Mean:
15
Signal Absent Mean:
10
Criterion:
12
Signal Present Std:
4
Signal Absent Std:
4

### The Basics

d', also called the sensitivity index, is the primary statistic used in Signal Detection Theory. At its core, d' is a measure of how far apart two distributions are. If two distributions are perfectly overlapping, d'=0 . If two distributions are 1 standard deviation apart, d'=1.
The equation is:
$d' = \frac{\mu_{SignalPresent} - \mu_{SignalAbsent}}{\sigma}$
where $\mu_{SignalPresent}$ is the mean of the distribution when there is a true signal present, $\mu_{SignalAbsent}$ is the mean of the distribution when there is no signal present, and $\sigma$ is the standard deviation of the distributions. Note that this formula assumes that the standard deviation ($\sigma$) is equal for both distributions. See below for discussion of the case where this assumption is not met.

### Hits, Misses, False Alarms, and Correct Rejections

Given the SignalPresent and SignalAbsent distributions, setting a "criterion" tells you the hit rate, miss rate, false alarm rate, and correct rejection rate. In plain English, the hit rate is the proportion of the time that a signal is reported when there actually is a signal, and the false alarm rate is the proportion of the time that a signal is reported when there is no signal present.

Remember, the miss rate is just one minus the hit rate, and the correct rejection rate is just one minus the false alarm rate, so knowing the hit rate gives you the miss rate, and knowing the false alarm rate gives you the correct rejection rate.

"Yes, there was a signal!" "No signal here..." ✅ Hit ❌ Miss ❌ False Alarm ✅ Correct Rejection

### What's the Criterion?

The criterion indicates the amount of evidence above which a signal will be reported. Thus, the hit rate is the proportion of responses from the SignalPresent distribution above the criterion, and the miss rate is the propoertion of resopnses from the SignalPresent distribution below the criterion. The false alarm rate is the proportion of responses from the SignalAbsent distribution above the criterion, and the correct rejection rate is the propoertion of responses from the SignalAbsent distribution below the criterion. A "conservative" criterion is relatively high, such that both hits and false alarms will be low. A "liberal" criterion is relatively low, such that both hits and false alarms will be high.

### ROC Curves

Receiver Operating Characteristic (ROC) Curves provide a visual representation of discriminability for a sensor. The x-axis is the false alarm rate and the y-axis is the hit rate. An ROC curve is composed of all of the false alarm rates and hit rates corresponding to all possible criteria one could choose from 0 to $\infty$. Note that d' is constant along this curve, because different points along the curve only differ in criterion, not in sensor sensitivity. Increasing d' moves the curve up and to the left, whereas decreasing d' brings the curve toward the$y=x$ unity line. The $y=x$ unity line represents a d' of 0, since hits and false alarms are exactly equal along that line, and thus, the Signal Present and Signal Absent distributions must be perfectly overlapping.

Often, the area under the ROC curve (AUC) is used to quantify how sensitive a sensor is. AUC ranges from 0 to 1, with 1 being a perfect sensor corresponding to a d' of $\infty$. How does the AUC numerically relate to the d' value?

$d' = \sqrt{2}Z(AUC)$
where Z() is the inverse CDF of the Gaussian distribution.

#### Unequal Standard Deviations

What if the standard deviations of the two distributions are not equal? No problem, just replace the denominator with the square root of the average variance!

$d' = \frac{\mu_{SignalPresent} - \mu_{SignalAbsent}}{\sqrt{\frac{1}{2}(\sigma_{SignaPresent}^2 + \sigma_{SignalAbsent}^2)}}$

#### Computing d' from the hit rate and false alarm rate

If you have the hit rate and false alarm rate and can assume the two distributions are approximately normal, you can also compute d' as:

$d' = Z(HitRate) - Z(FalseAlarmRate)$
where Z() is the inverse CDF of the Gaussian distribution.