function dist = cond_dist_gaussian(bnode, bnet)
% COND_DIST_GAUSSIAN Compute a Gaussian approx. to Pr(self) for a Gaussian node.
% dist = cond_dist_gaussian(bnode, bnet)
%
% If the discrete parents are hidden, we collapse the Conditional Gaussian to a single Gaussian.
% We assume the values of the continuous parents (if any) are known.

if ismember(bnode.self, bnet.observed_nodes)
  dist.mu = bnet.values(bnode.self);
  dist.Sigma = zeros(length(dist.mu));
  return;
end

dist = unobs_cond_dist_gaussian(bnode, bnet);
