Answers.Body: <p>I think an example could make you understand better.
  Suppose you want to calculate <span class="math-container">$P(X|S)$</span>, you now need to put evidence on <span class="math-container">$S$</span>(so you have to change all tables where <span class="math-container">$S$</span> appears making probability zero where <span class="math-container">$S$</span> does not appear).
  At this point, you can proceed with the collect and distribute method in order to propagate the evidence throughout the graph, in order to maintain the global consistency property. Now you can choose any <span class="math-container">$cluster\space V$</span> that contains <span class="math-container">$X$</span>, marginalize with respect to <span class="math-container">$S$</span>, and the job is done.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-04-07T12:37:23.913Z
Answers.Text: Thanks, now I finally understand where my confusion came from!
Answers.UserDisplayName: Genoma
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-04-07T12:19:06.127Z
Answers.LastActivityDate: 2021-04-07T14:23:24.473Z
Answers.LastEditDate: 2021-04-07T14:23:24.473Z
Answers.UserDisplayName: cipher
Body: <p>I'm currently studying the Junction Tree Algorithm: I'm referring to the process of transforming a Bayesian Network into a Junction Tree in order to apply inference. I understand how you build the Junction Tree, but I'm stuck on the idea of message passing.</p>
  <p>What exactly are these messages? Are they numbers, or vectors?</p>
  <p>If any of you could direct me to a numerical example that would be very appreciated.</p>
  
Tags: <bayesian-networks><bayesian-inference>
Title: What Constitutes Messages in Junction Tree Algorithm?
UserDisplayName: Genoma
ThreadText: # What Constitutes Messages in Junction Tree Algorithm?
  
  (Asked by: username_0 on 2021-04-05)
  
  I'm currently studying the Junction Tree Algorithm: I'm referring to the process of transforming a Bayesian Network into a Junction Tree in order to apply inference. I understand how you build the Junction Tree, but I'm stuck on the idea of message passing.
  
  What exactly are these messages? Are they numbers, or vectors?
  
  If any of you could direct me to a numerical example that would be very appreciated.
  
  **Tags:** bayesian-networks, bayesian-inference
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2021-04-07. Score: 0 | Accepted answer
  
  I think an example could make you understand better.
  Suppose you want to calculate $P(X|S)$, you now need to put evidence on $S$(so you have to change all tables where $S$ appears making probability zero where $S$ does not appear).
  At this point, you can proceed with the collect and distribute method in order to propagate the evidence throughout the graph, in order to maintain the global consistency property. Now you can choose any $cluster\space V$ that contains $X$, marginalize with respect to $S$, and the job is done.
  
  > **Comments:**
  > **username_0**: Thanks, now I finally understand where my confusion came from!  
  
  ---
  
  