Skip to main content
added 7 characters in body
Source Link
mokebe
  • 273
  • 4
  • 12

Assume we have some linear regression of the form $y^{(i)}=\theta^{T}x^{(i)}+e^{(i)}$$$y^{(i)}=\theta^{T}x^{(i)}+e^{(i)}$$

where: $P(y^{(i)}|x^{(i)},\theta)=\frac{1}{\sqrt{2\pi}\sigma}exp(-\frac{(y^{(i)}-\theta^{T}x^{(i)})^{2}}{2\sigma^{2}})$$$P(y^{(i)}|x^{(i)},\theta)=\frac{1}{\sqrt{2\pi}\sigma}exp(-\frac{(y^{(i)}-\theta^{T}x^{(i)})^{2}}{2\sigma^{2}})$$

Then using Bayes Rule we obtain some parameter distribution $p(\theta|S)$ where S is our dataset.

My problem is with derivation of posterior predictive distribution which is given in notes as follows:

Given new test point $x_{*}$ probability distribution over possible outputs(posterior predictive distribution) is:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta)p(\theta|S)d\theta $$$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta)p(\theta|S)d\theta $$

And I dont fully understand why exactly we have $p(\theta|S)$ instead of $p(\theta)$ in above formula, because my reasoning is following:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta,S)p(\theta)d\theta = \int_{\theta}p(y_{*}|x_{*},\theta)p(\theta)d\theta $$$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta,S)p(\theta)d\theta = \int_{\theta}p(y_{*}|x_{*},\theta)p(\theta)d\theta $$ (By marginal probability and independence of $x_{*}$ from $S$)

Assume we have some linear regression of the form $y^{(i)}=\theta^{T}x^{(i)}+e^{(i)}$

where: $P(y^{(i)}|x^{(i)},\theta)=\frac{1}{\sqrt{2\pi}\sigma}exp(-\frac{(y^{(i)}-\theta^{T}x^{(i)})^{2}}{2\sigma^{2}})$

Then using Bayes Rule we obtain some parameter distribution $p(\theta|S)$ where S is our dataset.

My problem is with derivation of posterior predictive distribution which is given in notes as follows:

Given new test point $x_{*}$ probability distribution over possible outputs(posterior predictive distribution) is:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta)p(\theta|S)d\theta $

And I dont fully understand why exactly we have $p(\theta|S)$ instead of $p(\theta)$ in above formula, because my reasoning is following:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta,S)p(\theta)d\theta = \int_{\theta}p(y_{*}|x_{*},\theta)p(\theta)d\theta $ (By marginal probability and independence of $x_{*}$ from $S$)

Assume we have some linear regression of the form $$y^{(i)}=\theta^{T}x^{(i)}+e^{(i)}$$

where: $$P(y^{(i)}|x^{(i)},\theta)=\frac{1}{\sqrt{2\pi}\sigma}exp(-\frac{(y^{(i)}-\theta^{T}x^{(i)})^{2}}{2\sigma^{2}})$$

Then using Bayes Rule we obtain some parameter distribution $p(\theta|S)$ where S is our dataset.

My problem is with derivation of posterior predictive distribution which is given in notes as follows:

Given new test point $x_{*}$ probability distribution over possible outputs(posterior predictive distribution) is:

$$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta)p(\theta|S)d\theta $$

And I dont fully understand why exactly we have $p(\theta|S)$ instead of $p(\theta)$ in above formula, because my reasoning is following:

$$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta,S)p(\theta)d\theta = \int_{\theta}p(y_{*}|x_{*},\theta)p(\theta)d\theta $$ (By marginal probability and independence of $x_{*}$ from $S$)

deleted 1 character in body
Source Link
mokebe
  • 273
  • 4
  • 12

Assume we have some linear regression of the form $y^{(i)}=\theta^{T}x^{(i)}+e^{(i)}$

where: $P(y^{(i)}|x^{(i)},\theta)=\frac{1}{\sqrt{2\pi}\sigma}exp(-\frac{(y^{(i)}-\theta^{T}x^{(i)})^{2}}{2\sigma^{2}})$

Then using Bayes Rule we obtain some parameter distribution $p(\theta|S)$ where S is our dataset.

My problem is with derivation of posterior predictive distribution which is given in notes as follows:

Given new test point $x_{*}$ probability distribution over possible outputs(posterior predictive distribution) is:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta)p(\theta)|S)d\theta $$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta)p(\theta|S)d\theta $

And I dont fully understand why exactly we have $p(\theta|S)$ instead of $p(\theta)$ in above formula, because my reasoning is following:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta,S)p(\theta))d\theta = \int_{\theta}p(y_{*}|x_{*},\theta)p(\theta))d\theta $$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta,S)p(\theta)d\theta = \int_{\theta}p(y_{*}|x_{*},\theta)p(\theta)d\theta $ (By marginal probability and independence of $x_{*}$ from $S$)

Assume we have some linear regression of the form $y^{(i)}=\theta^{T}x^{(i)}+e^{(i)}$

where: $P(y^{(i)}|x^{(i)},\theta)=\frac{1}{\sqrt{2\pi}\sigma}exp(-\frac{(y^{(i)}-\theta^{T}x^{(i)})^{2}}{2\sigma^{2}})$

Then using Bayes Rule we obtain some parameter distribution $p(\theta|S)$ where S is our dataset.

My problem is with derivation of posterior predictive distribution which is given in notes as follows:

Given new test point $x_{*}$ probability distribution over possible outputs(posterior predictive distribution) is:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta)p(\theta)|S)d\theta $

And I dont fully understand why exactly we have $p(\theta|S)$ instead of $p(\theta)$ in above formula, because my reasoning is following:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta,S)p(\theta))d\theta = \int_{\theta}p(y_{*}|x_{*},\theta)p(\theta))d\theta $ (By marginal probability and independence of $x_{*}$ from $S$)

Assume we have some linear regression of the form $y^{(i)}=\theta^{T}x^{(i)}+e^{(i)}$

where: $P(y^{(i)}|x^{(i)},\theta)=\frac{1}{\sqrt{2\pi}\sigma}exp(-\frac{(y^{(i)}-\theta^{T}x^{(i)})^{2}}{2\sigma^{2}})$

Then using Bayes Rule we obtain some parameter distribution $p(\theta|S)$ where S is our dataset.

My problem is with derivation of posterior predictive distribution which is given in notes as follows:

Given new test point $x_{*}$ probability distribution over possible outputs(posterior predictive distribution) is:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta)p(\theta|S)d\theta $

And I dont fully understand why exactly we have $p(\theta|S)$ instead of $p(\theta)$ in above formula, because my reasoning is following:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta,S)p(\theta)d\theta = \int_{\theta}p(y_{*}|x_{*},\theta)p(\theta)d\theta $ (By marginal probability and independence of $x_{*}$ from $S$)

Source Link
mokebe
  • 273
  • 4
  • 12

Posterior predictive distribution(Bayes regression)

Assume we have some linear regression of the form $y^{(i)}=\theta^{T}x^{(i)}+e^{(i)}$

where: $P(y^{(i)}|x^{(i)},\theta)=\frac{1}{\sqrt{2\pi}\sigma}exp(-\frac{(y^{(i)}-\theta^{T}x^{(i)})^{2}}{2\sigma^{2}})$

Then using Bayes Rule we obtain some parameter distribution $p(\theta|S)$ where S is our dataset.

My problem is with derivation of posterior predictive distribution which is given in notes as follows:

Given new test point $x_{*}$ probability distribution over possible outputs(posterior predictive distribution) is:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta)p(\theta)|S)d\theta $

And I dont fully understand why exactly we have $p(\theta|S)$ instead of $p(\theta)$ in above formula, because my reasoning is following:

$p(y_{*}|x_{*},S)=\int_{\theta}p(y_{*}|x_{*},\theta,S)p(\theta))d\theta = \int_{\theta}p(y_{*}|x_{*},\theta)p(\theta))d\theta $ (By marginal probability and independence of $x_{*}$ from $S$)