import matplotlib
matplotlib.use('Agg')

import pymc
import mymodel

S = pymc.MCMC(mymodel, db='pickle')
S.sample(iter=10000, burn=5000, thin=2)

pymc.Matplot.plot(S)
print("finish")


import matplotlib
matplotlib.use('Agg')

import pymc
import mymodel

S = pymc.MCMC(mymodel, db='pickle')
S.sample(iter=10000, burn=5000, thin=2)

pymc.Matplot.plot(S)
print("finish")

