GithubHelp home page GithubHelp logo

nu > 0 about conjugatepriors.jl HOT 3 OPEN

juliastats avatar juliastats commented on May 27, 2024
nu > 0

from conjugatepriors.jl.

Comments (3)

krylea avatar krylea commented on May 27, 2024

(I should clarify this is referring to the NormalGamma distribution)

from conjugatepriors.jl.

mschauer avatar mschauer commented on May 27, 2024

Hm, with nu = 0, this is not a proper distribution and one cannot sample anymore from it, compare

mu = rand(Normal(d.mu, sqrt(1./(tau2*d.nu))))
The originating package Distribution.jl in general only supports proper distributions. As priors, improper distributions still make sense. What to do?

from conjugatepriors.jl.

sourish-cmi avatar sourish-cmi commented on May 27, 2024

If you choose nu=0 the marginal prior distribution for location parameter for the Normal Gamma model would be Cauchy distribution. This is a proper distribution for which mean and variance do not exist. However, because prior is a proper distribution, the posterior distribution turns out to be just fine. That is why even if you use nu=0 the simulation works fine. It is not an accident. You can look into Andrew Gelman's book. He gave a beautiful explanation about this (Chapter 2).

Ref: Bayesian Data Analysis (By Andrew Gelman and etal.) Second Ed.

https://www.amazon.in/Bayesian-Analysis-Chapman-Statistical-Science/dp/1439840954/ref=sr_1_1?crid=20GZF006GVZ5E&keywords=bayesian+data+analysis+gelman&qid=1642527457&sprefix=bayesian+data+analysis+ge%2Caps%2C345&sr=8-1

from conjugatepriors.jl.

Related Issues (16)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.