1. Home
  2. Explore
  3. Statistics
  4. Probabilistic Modeling

Study methods

Flashcards
Quiz
Fill in the blanks
Written test
Lesson
Notes
Podcast
Content

Probabilistic Modeling

  • 56Unfamiliar
  • 0Learning
  • 0Familiar
  • 0Mastered
Topic: Joint Distributions

What does a joint distribution specify for a collection of random variables?

56 questions

  1. 1

    What does a joint distribution specify for a collection of random variables?

    Model answer

    It gives the probability of every possible joint assignment to all the random variables.

    Explanation

    A joint distribution contains complete information about the probabilistic model and can be represented as a function, equation, program, or table.

  2. 2

    Why is a joint distribution sufficient for answering inference questions?

    Model answer

    It contains the probabilities needed to calculate conditional probabilities and update beliefs after observing evidence.

    Explanation

    Inference uses the joint to compare assignments consistent with the evidence and to calculate the probabilities of the variables of interest.

  3. 3

    In the elephant example, what was observed and what was inferred?

    Model answer

    Weight was observed, and the model updated its belief about the elephant’s gender.

    Explanation

    The model treated gender as a Bernoulli random variable and weight as evidence that could provide information about it.

  4. 4

    Why did visual-acuity inference require more than one application of Bayes’ theorem?

    Model answer

    Visual acuity could take many values, so the belief had to be updated for every possible value rather than just two outcomes.

    Explanation

    The class represented possible acuity levels in a dictionary and used a loop to apply Bayes’ theorem across the values.

  5. 5

    In Bayes’ theorem, what roles do the prior, likelihood, and posterior play?

    Model answer

    The prior is the belief before evidence, the likelihood measures how probable the evidence is under a state, and the posterior is the updated belief.

    Explanation

    Inference combines the prior and likelihood to calculate the posterior belief about the unknown state.

  6. 6

    Why can a program calculate all Bayes-theorem numerators and then normalize them?

    Model answer

    Normalizing divides each numerator by their sum, which supplies the shared denominator required for the posterior probabilities.

    Explanation

    The sum of the numerators over all possible states is the evidence probability, as given by the law of total probability.

  7. 7

    How many entries are needed to represent a joint table for nnn binary random variables?

    Model answer

    A complete table has 2n2^n2n entries, although one entry can be inferred because all probabilities sum to 111.

    Explanation

    Each binary variable doubles the number of possible joint assignments, so the table grows exponentially.

  8. 8

    Why is a joint probability table impractical for modeling many binary variables?

    Model answer

    Its size grows exponentially with the number of variables, making it costly to store and estimate.

    Explanation

    For nnn binary variables, the table requires 2n2^n2n joint probabilities before accounting for the one redundant entry.

  9. 9

    Why do probabilistic models need a more compact representation than a joint table?

    Model answer

    A compact representation can exploit assumptions about how variables relate, avoiding the need to list every joint assignment separately.

    Explanation

    Bayesian networks use a graph and conditional probability tables to represent a joint distribution with fewer probabilities when the structure is suitable.

  10. 10

    How can representing a random variable as a dictionary help with inference?

    Model answer

    The dictionary can map each possible value of the variable to its probability, allowing the model to update beliefs across all values.

    Explanation

    A lookup retrieves the probability associated with a particular assignment, while a loop can process a variable with many possible values.

  11. 11

    What are the main steps for specifying a Bayesian network?

    Model answer

    Draw directed arrows between variables to represent the hypothesized structure, then specify each variable’s probabilities given its parents.

    Explanation

    The graph describes the assumed relationships, and the conditional probabilities quantify the behavior at each node.

  12. 12

    In a Bayesian network, what does a directed arrow represent?

    Model answer

    It represents a hypothesized causal influence from one random variable to another.

    Explanation

    For example, the model may represent flu as causing fever, rather than fever as causing flu.

  13. 13

    Why can observing an effect change belief about its cause even when the causal arrow points the other way?

    Model answer

    Probabilistic evidence can update beliefs in either direction, even though the hypothesized causal relationship is directed.

    Explanation

    Observing fever can raise the probability of flu, although the model represents flu as causing fever.

  14. 14

    What probability must be specified for a node with no parents?

    Model answer

    Its unconditional probability distribution must be specified.

    Explanation

    With no parent variables to condition on, the node’s probability is given directly, as with a prior probability.

  15. 15

    What does a conditional probability table specify for a node with parents?

    Model answer

    It specifies the node’s probability distribution for every possible assignment to its immediate parents.

    Explanation

    For a binary node, it is enough to give the probability of one outcome for each parent assignment; the other outcome’s probability is its complement.

  16. 16

    How many parent assignments must be considered for a node with two binary parents?

    Model answer

    There are four assignments, so the table must specify the node’s probability for each of those four cases.

    Explanation

    Each of the two parents can take either of two values, giving 22=42^2=422=4 combinations.

  17. 17

    How does the number of a node’s parents affect the size of its conditional probability table?

    Model answer

    For binary parents, the number of parent assignments grows as 2k2^k2k, where kkk is the number of parents.

    Explanation

    Adding parents increases the number of cases for which the node’s conditional probabilities must be specified.

  18. 18

    What independence assumption is conveyed by leaving an arrow out of a Bayesian network?

    Model answer

    The graph assumes that the omitted direct causal relationship does not affect the modeled dependencies; this can imply conditional independence.

    Explanation

    The arrows encode structural assumptions that let the model represent a joint distribution more compactly. The exact independence implications depend on the graph.

  19. 19

    Why must a Bayesian network be acyclic?

    Model answer

    A directed cycle would make variables depend on one another in a circular way, breaking the network’s generative ordering.

    Explanation

    The model must allow variables to be generated from their parents without a cycle such as undergraduate status causing tiredness while tiredness causes undergraduate status.

  20. 20

    What trade-off arises when adding more arrows to a Bayesian network?

    Model answer

    More arrows can represent more relationships, but they require more probabilities to estimate and can make the model less practical or less accurate.

    Explanation

    A richer graph can fit more detail, but estimating many parameters is difficult; the model’s accuracy may degrade as unnecessary complexity is added.

  21. 21

    Where can the probabilities in a Bayesian network come from?

    Model answer

    They can be estimated from data or supplied as informed estimates by experts.

    Explanation

    The lecture cautions that expert-supplied values are assumptions and should be treated carefully.

  22. 22

    How does a Bayesian network factorize a joint probability?

    Model answer

    It expresses the joint as the product, over all nodes, of each node’s probability conditioned on its parents.

    Explanation

    For variables X1,…,XnX_1,\ldots,X_nX1​,…,Xn​ with parent sets Pa⁡(Xi)\operatorname{Pa}(X_i)Pa(Xi​), the factorization is P(X1,…,Xn)=∏iP(Xi∣Pa⁡(Xi))P(X_1,\ldots,X_n)=\prod_i P(X_i\mid \operatorname{Pa}(X_i))P(X1​,…,Xn​)=∏i​P(Xi​∣Pa(Xi​)).

  23. 23

    Using the lecture’s values, what is the probability that flu is absent, undergraduate status is present, fever is absent, and tiredness is present?

    Model answer

    The probability is 0.9×0.8×0.95×0.8=0.54720.9\times0.8\times0.95\times0.8=0.54720.9×0.8×0.95×0.8=0.5472.

    Explanation

    The factors are the probability of no flu, the probability of being an undergraduate, the probability of no fever given no flu, and the probability of tiredness given no flu and undergraduate status.

  24. 24

    How does sampling from a Bayesian network generate a joint assignment?

    Model answer

    Sample variables without parents first, then sample each remaining variable using the values of its parents.

    Explanation

    Once every variable has been sampled, the result is a complete assignment drawn from the joint distribution represented by the network.

  25. 25

    What does it mean to sample a fake person from the WebMD Bayesian network?

    Model answer

    It means drawing values for all the modeled variables—such as flu, undergraduate status, fever, and tiredness—according to the network’s probabilities.

    Explanation

    Different samples can produce different assignments, with their frequencies reflecting the joint distribution.

  26. 26

    How is sampling from a Bayesian network different from inference after observing symptoms?

    Model answer

    Sampling generates a complete assignment without evidence, whereas inference updates beliefs after some variable values have been observed.

    Explanation

    For example, generating a person’s symptoms is sampling; estimating the probability of flu after learning that the person has a fever is inference.

  27. 27

    Why is the sampling procedure called a generative story?

    Model answer

    It describes a proposed process in which parent variables are generated first and child variables are generated from them.

    Explanation

    The network encodes how the model supposes a complete assignment to the variables could be produced.

  28. 28

    How does a Bayesian network’s sampling representation relate to a joint probability table?

    Model answer

    Sampling in the network produces assignments according to the same joint distribution that could be represented by a joint table.

    Explanation

    The network is a compact way to specify the joint, while the table lists the probability of every complete assignment explicitly.

  29. 29

    How did the four-variable example illustrate the possible compression of a Bayesian network?

    Model answer

    It represented the model with eight probabilities rather than the sixteen entries in a full table for four binary variables.

    Explanation

    The savings come from the network’s structure and its implied independence assumptions.

  30. 30

    Why can a Bayesian network become exponentially large if many arrows are added?

    Model answer

    A node with many parents needs probabilities for many parent assignments, and those assignments grow exponentially with the number of parents.

    Explanation

    For binary parents, a node with kkk parents has 2k2^k2k parent configurations.

  31. 31

    How is a conditional probability defined in terms of joint probabilities?

    Model answer

    For evidence EEE with nonzero probability, P(A∣E)=P(A,E)P(E)P(A\mid E)=\frac{P(A,E)}{P(E)}P(A∣E)=P(E)P(A,E)​.

    Explanation

    The numerator is the probability that both the target event and evidence occur; the denominator is the probability of the evidence.

  32. 32

    Why can the numerator of a conditional probability be calculated directly from a joint model?

    Model answer

    The numerator specifies a joint assignment or event, whose probability is available from the joint distribution.

    Explanation

    A Bayesian network can provide that joint probability through its factorization.

  33. 33

    How can you calculate the probability of evidence when it leaves a target variable unspecified?

    Model answer

    Sum the joint probabilities over all possible values of the unspecified variable.

    Explanation

    This process is marginalization, which combines the mutually exclusive joint cases that match the evidence.

  34. 34

    How would you calculate P(flu=1∣E)P(\text{flu}=1\mid E)P(flu=1∣E) when EEE specifies values for the other modeled variables?

    Model answer

    Divide the joint probability with flu present and evidence EEE by the sum of the joint probabilities for flu present and flu absent with the same evidence.

    Explanation

    The denominator marginalizes over the two possible flu values, producing the probability of the evidence alone.

  35. 35

    What role does the law of total probability play in inference from a joint distribution?

    Model answer

    It obtains a probability by summing over the possible values of variables that are not specified.

    Explanation

    Those alternative assignments are mutually exclusive and together cover the possibilities being marginalized out.

  36. 36

    What general inference capability follows from having a way to calculate the joint distribution?

    Model answer

    Any conditional probability query can be answered by calculating the required joint probabilities and marginalizing over unspecified variables.

    Explanation

    This applies even when the evidence and the variable of interest involve different subsets of the model’s variables.

  37. 37

    What is the event-level definition of independence?

    Model answer

    Events AAA and BBB are independent when P(A∩B)=P(A)P(B)P(A\cap B)=P(A)P(B)P(A∩B)=P(A)P(B).

    Explanation

    Under this condition, knowing that one event occurred does not change the probability of the other.

  38. 38

    What condition makes two random variables independent?

    Model answer

    For every pair of values xxx and yyy, their joint probability must satisfy P(X=x,Y=y)=P(X=x)P(Y=y)P(X=x,Y=y)=P(X=x)P(Y=y)P(X=x,Y=y)=P(X=x)P(Y=y).

    Explanation

    Independence of random variables is a stronger claim than independence of one selected pair of events because the condition must hold for every value assignment.

  39. 39

    In the two-dice example, are the events D1=1D_1=1D1​=1 and S=7S=7S=7 independent?

    Model answer

    Yes. Each event has probability 1/61/61/6, and their joint probability is 1/36=(1/6)(1/6)1/36=(1/6)(1/6)1/36=(1/6)(1/6).

    Explanation

    Here D1D_1D1​ is the first die and SSS is the sum of the two dice; the independence equation holds for these particular events.

  40. 40

    In the two-dice example, are the events D1=1D_1=1D1​=1 and S=5S=5S=5 independent?

    Model answer

    No. Knowing that the first die is 111 changes the probability that the sum is 555.

    Explanation

    The independence condition does not hold for this event pair, even though the previous pair involving a sum of 777 was independent.

  41. 41

    Why does independence of one event pair not prove that two random variables are independent?

    Model answer

    Random variables are independent only if the independence equation holds for every pair of their possible values.

    Explanation

    A single pair of assignments can be independent while another pair is dependent.

  42. 42

    How can a scatterplot suggest whether two numerical random variables are related?

    Model answer

    If knowing one variable’s value helps predict the other, the variables appear related; if it provides little information, they appear more independent.

    Explanation

    The lecture used patterns in scatterplots to motivate a numerical measure of how variables vary together.

  43. 43

    What does covariance measure?

    Model answer

    Covariance measures whether two random variables tend to deviate from their means in the same or opposite directions.

    Explanation

    It summarizes how the variables vary together, but it does not provide a complete causal explanation.

  44. 44

    What is the definition of covariance using deviations from the means?

    Model answer

    For random variables XXX and YYY, Cov⁡(X,Y)=E[(X−E[X])(Y−E[Y])]\operatorname{Cov}(X,Y)=\mathbb{E}[(X-\mathbb{E}[X])(Y-\mathbb{E}[Y])]Cov(X,Y)=E[(X−E[X])(Y−E[Y])].

    Explanation

    Each product compares how far an observed pair is from the means of its two variables.

  45. 45

    What is an equivalent formula for covariance that can be convenient to calculate?

    Model answer

    Cov⁡(X,Y)=E[XY]−E[X]E[Y]\operatorname{Cov}(X,Y)=\mathbb{E}[XY]-\mathbb{E}[X]\mathbb{E}[Y]Cov(X,Y)=E[XY]−E[X]E[Y].

    Explanation

    This form uses the expectation of the product and the individual expectations.

  46. 46

    What sign does a covariance contribution have when both values are on the same side of their means?

    Model answer

    It is positive when both values are above their means or both are below them.

    Explanation

    In either case, the two deviations have the same sign, so their product is positive.

  47. 47

    What sign does a covariance contribution have when one value is above its mean and the other is below its mean?

    Model answer

    It is negative because the two deviations have opposite signs.

    Explanation

    The product of a positive deviation and a negative deviation is negative.

  48. 48

    Why can a dataset have covariance close to zero even when individual points make positive or negative contributions?

    Model answer

    Positive and negative contributions can cancel when averaged across the data.

    Explanation

    Covariance is an expectation over the joint values of the variables.

  49. 49

    What can covariance reveal about music preferences in the example?

    Model answer

    It can show which genres tend to vary together, such as the positive covariance of punk or metal with rock and the negative covariance of metal or hard rock with pop.

    Explanation

    These relationships can help identify patterns among the measured music preferences.

  50. 50

    Why is covariance only a first step toward discovering a causal structure from data?

    Model answer

    It identifies variables that vary together but does not, by itself, establish which variable causes another.

    Explanation

    The modeler must use the observed relationships and other knowledge to propose a causal structure.

  51. 51

    Why were simple statistics and deep learning insufficient for identifying beginner programmers’ misconceptions in the Code.org example?

    Model answer

    They did not reliably interpret students’ short programs well enough to identify the underlying misconceptions.

    Explanation

    The lecture motivated a probabilistic generative model for the ways beginners produce code, inspired by models of how people draw characters; that approach outperformed humans on the bug-identification task.

  52. 52

    What kinds of variables might a symptom-checking model include?

    Model answer

    It might include disease variables, symptom variables, and prior-condition variables such as age.

    Explanation

    These variables can jointly influence the probabilities of symptoms and diseases.

  53. 53

    In a symptom-checking model, how does observing nausea and tiredness support an inference about flu?

    Model answer

    The observations serve as evidence that can update the model’s belief about whether the person has the flu.

    Explanation

    Inference uses observed variables to update beliefs about other variables in the same probabilistic model.

  54. 54

    Can evidence about one set of variables be used to update belief about a different variable in the same model?

    Model answer

    Yes. Observing some variables can update beliefs about any other variables represented in the joint model.

    Explanation

    For example, observed symptoms could update beliefs about a disease or a prior condition.

  55. 55

    Why can a model use a simple causal structure even though real-world relationships are more complicated?

    Model answer

    A simplified structure can capture broad patterns while keeping the model manageable, even though it will not represent every real-world influence.

    Explanation

    The lecture notes that causal models are imperfect, and that adding too many relationships can make the model harder to estimate.

  56. 56

    How can data help estimate the probabilities in a symptom model?

    Model answer

    Observed cases can be used to estimate frequencies, such as the proportion of people with a condition who report a particular symptom.

    Explanation

    These estimated frequencies can populate the network’s prior probabilities and conditional probability tables.

1 of 56
Question 1 of 56

Ask anything

We've read this whole study set, so questions about it get the best answers.

FlashcardsQuizFill in the blanksWritten testLessonNotesPodcastContent