Phi Coefficient Formula:
From: | To: |
Definition: The Phi coefficient (φ) is a measure of association between two binary variables (2×2 contingency table).
Purpose: It's used in statistics to determine the degree of association between two binary variables, similar to Pearson's correlation for binary data.
The calculator uses the formula:
Where:
Explanation: The numerator measures the difference between concordant and discordant pairs, while the denominator normalizes this difference.
Details:
Tips: Enter all four values from your 2×2 contingency table (TP, TN, FP, FN). All values must be ≥ 0.
Q1: What's the difference between Phi and Pearson correlation?
A: Phi is specifically for binary variables, while Pearson's is for continuous variables. Phi is mathematically equivalent to Pearson's for binary data.
Q2: When is Phi coefficient undefined?
A: When the denominator is zero, which happens if any marginal total is zero (e.g., TP+FP=0).
Q3: What's a "good" Phi value?
A: Interpretation depends on context, but generally:
Q4: Can Phi be negative?
A: Yes, negative values indicate an inverse relationship between variables.
Q5: What fields use Phi coefficient?
A: Psychology, medicine, machine learning (especially for binary classification evaluation), and social sciences.