MATLAB Answers

0

Calculating Credible Intervals for observed data

Asked by SRINJAY CHANDRASEKAR on 23 Jul 2019
Latest activity Answered by Kavya Vuriti on 13 Aug 2019
Hey everyone,
I'm trying to construct a 90% credible interval using normal priors, for two variables namely GDP and GDI. However, I'm not sure how i can do that. Can someone please help me with the codes for it?
Thanks in advance.

  0 Comments

Sign in to comment.

1 Answer

回答者: Kavya Vuriti 2019 年 8 月 13 日

I think credible interval is analogous to confidence interval. To find confidence interval, calculate mean and standard deviation of the data. Then calculate the standard error of the mean at each value of the independent variable, multiply it by the 90% values of the t-distribution calculated using tinv function, then add and subtract those values from the mean.
The probabilities in tinv function can be specified as [0.05 0.95] for calculating 90% probability intervals.

  0 Comments

Sign in to comment.