Questions tagged [pymc3]

PyMC (formerly PyMC3) is a Python module that implements Bayesian statistical models and fitting algorithms, including Markov chain Monte Carlo. Its flexibility and extensibility make it applicable to a large suite of problems. Along with core sampling functionality, PyMC includes methods for summarizing output, plotting, goodness-of-fit and convergence diagnostics.

PyMC is a Python module that implements Bayesian statistical models and fitting algorithms, including Markov chain Monte Carlo.

Its flexibility and extensibility make it applicable to a large suite of problems. Along with core sampling functionality, PyMC includes methods for summarizing output, plotting, goodness-of-fit and convergence diagnostics.

706 questions
0
votes
1 answer

How to sample independently with pymc3

I am working with a simple bivariate normal model with a somewhat unconventional prior. The main issue I have is that my posteriors are inconsistent from one run to the next, which I'm guessing is related to an issue of high dependence between…
deepee
  • 1
  • 2
0
votes
1 answer

Logistic Regression with pymc3 - what's the prior for build in glm?

I could not find good explanation for what's going on exactly by using glm with pymc3 in case of logistic regression. So I compared the GLM version to an explicit pymc3 model. I started to write an ipython notebook for documentation,…
chris elgoog
  • 145
  • 8
0
votes
0 answers

Negative binomial model cannot find starting position to sample

I am having difficulties running a PYMC3 model when the observed data is discrete. Oddly, if the observed data contains the value zero (0.), the model will run. I've read in other posts that that suggest using start =…
M. Regan
  • 231
  • 1
  • 8
0
votes
1 answer

pymc fitting with several observations a time

I am trying to use pymc to fit the time evolution of oscillating data. Here I have not just one point per time step, but several of them. I simply cannot find an efficient way to make this work in pymc3 as it always raises some input value errors.…
fretchen
  • 13
  • 7
0
votes
1 answer

Softmax choice probabilities with Categorical in PyMC3

I am trying to perform a parameter estimation for a single parameter of a softmax choice function in the following scenario: In each trial, three option values are given (e.g., [1,2,3]), and a subject makes a choice between the options (0, 1 or 2).…
Felix
  • 1
  • 3
0
votes
1 answer

Is it possible to use NUTS in PyMC3 with a model that involves the eigendecomposition of parameters?

I have a model where the likelihood involves computing the sum of all the terms in the matrix P = U exp(tD) U^-1 Where UDU^-1 = Q and Q is my matrix of parameters.If I wanted to use NUTS in PyMC3, NUTS would have to be able to compute the…
user52291
  • 161
  • 2
  • 2
  • 4
0
votes
1 answer

Using pymc3 to fit Student's t distribution

Not sure if I am doing something silly or pymc3 has a bug, but trying to fit T distribution to normal I get number of degrees of freedom (0.18 to 0.25, I'd expect something high, 4-5 at least). Of course I am getting the same error if I try T…
0
votes
1 answer

Massive memory usage when defining regression model

I'm having problems with memory when running a Poisson regression model. With the data loaded in and ready for the model, python is using about 650 MB of memory. As soon as I create the model, import theano.tensor as t with pm.Model() as…
Mat Leonard
  • 253
  • 1
  • 2
  • 6
0
votes
1 answer

Collapsed sampling/individual Metropolis-Hastings steps

My model has three parameters, say theta_1, theta_2 and nu. I want to sample theta_1, theta_2 from the posterior with nu marginalized out (which can be done analytically), i.e. from p(theta_1, theta_2 | D) instead of p(theta_1, theta_2, nu | D)…
devnull
  • 147
  • 1
  • 5
0
votes
1 answer

Defining the exponential prior with jumping order of magnitude in parameter space

I want to define an Exponential prior for a parameter as following Therefore I have defined it in pymc with @pm.stochastic def MASS(value=math.pow(10,15), rate = math.pow(10,15)): """mass is a stochastic parameter with exponential…
Dalek
  • 4,168
  • 11
  • 48
  • 100
-1
votes
2 answers

How can I import pymc3 in anaconda?

Thanks for helping me. I use windows 7 and want to use pymc3 in python3.7, but it doesn't work, and I get no idea. Should I install other packages or there is any solution? I have tried all that I can see on the internet. I don't know why I can't…
-1
votes
1 answer

How to Solve Error in Python?

I want to do a Bayesian analysis in python with a custom defined likelihood function. Below is my code. I get the error when I run the code. Does anyone know what the problem is? Thanks! import pandas as pd import numpy as np import…
H2H
  • 31
  • 5
-1
votes
1 answer

pymc3 error. AttributeError: module 'arviz' has no attribute 'geweke'

I got the following error: AttributeError: module 'arviz' has not attribute 'geweke'. See the attached full stack trace below: How can I fix it?
-1
votes
1 answer

Tensorflow probability not giving the same results as PyMC3

I have previousely used PyMC3 and am now looking to use tensorflow probability. I have built some model in both, but unfortunately, I am not getting the same answer. In fact, the answer is not that close. # definition of the joint_log_prob to…
usman Farooq
  • 151
  • 1
  • 12
-1
votes
1 answer

Bayesian Network Model Size Calculation

How do you calculate the (storage) size of a Bayesia Network model with n nodes/features/columns/attributes and k arcs? The model may be generated through pymc or pomegranate.
Reacher234
  • 230
  • 2
  • 11
1 2 3
47
48