stochastic stuff for pgss