PracHub
QuestionsPremiumLearningGuidesInterview PrepNEWCoaches
|Home/Statistics & Math/Meta

Compute posterior for accurate-but-rare classifier

Last updated: Mar 29, 2026

Quick Overview

This question evaluates understanding of Bayes' theorem and probabilistic reasoning for interpreting classifier outputs, specifically computing posterior probabilities given sensitivity, specificity, and prevalence.

  • medium
  • Meta
  • Statistics & Math
  • Data Scientist

Compute posterior for accurate-but-rare classifier

Company: Meta

Role: Data Scientist

Category: Statistics & Math

Difficulty: medium

Interview Round: Onsite

In a population, 5% are 'bad' users and 95% are 'good'. A screening model predicts 'bad' with sensitivity 0.95 (P(pred=bad | bad)=0.95) and specificity 0.95 (P(pred=good | good)=0.95). (a) If the model predicts 'bad' for a user, compute P(user is actually bad). (b) If the model predicts 'good', compute P(user is actually good). (c) Explain how these posteriors change with the prevalence and why this illustrates the base-rate effect.

Quick Answer: This question evaluates understanding of Bayes' theorem and probabilistic reasoning for interpreting classifier outputs, specifically computing posterior probabilities given sensitivity, specificity, and prevalence.

Related Interview Questions

  • Compute probability an account is fake - Meta (easy)
  • Compute Bayes probability for fake accounts - Meta (easy)
  • Compute probabilities for chatbot response quality - Meta (easy)
  • Compute posterior fake probability using Bayes' rule - Meta (medium)
  • Estimate bots and CI from DAU spike - Meta (medium)
Meta logo
Meta
Oct 13, 2025, 9:49 PM
Data Scientist
Onsite
Statistics & Math
2
0

Bayes' Theorem: Interpreting Screening Model Predictions

Context

You are evaluating a binary screening model that flags "bad" users in a population. The model has known sensitivity and specificity, and the population has a known prevalence of "bad" users.

  • Prevalence: P(bad) = 5%, P(good) = 95%.
  • Sensitivity: P(pred = bad | bad) = 0.95.
  • Specificity: P(pred = good | good) = 0.95 (so false positive rate = 0.05).

Tasks

(a) If the model predicts "bad" for a user, compute P(user is actually bad).

(b) If the model predicts "good" for a user, compute P(user is actually good).

(c) Explain how these posterior probabilities change with the prevalence and why this illustrates the base-rate effect.

Solution

Show

Comments (0)

Sign in to leave a comment

Loading comments...

Browse More Questions

More Statistics & Math•More Meta•More Data Scientist•Meta Data Scientist•Meta Statistics & Math•Data Scientist Statistics & Math
PracHub

Master your tech interviews with 7,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.