Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reproducible Analysis #147

Open
ktmeaton opened this issue Apr 6, 2021 · 2 comments
Open

Reproducible Analysis #147

ktmeaton opened this issue Apr 6, 2021 · 2 comments

Comments

@ktmeaton
Copy link
Contributor

ktmeaton commented Apr 6, 2021

Is there a way to make analyses reproducible, perhaps by setting a random seed? Specifically, I'm using the run function of the TreeTime class to estimate a clock model.

I've tried:

random.seed(1234)

and

numpy.random.seed(1234)

but the results still change slightly each time.

Thanks!

@rneher
Copy link
Member

rneher commented Apr 11, 2021

Hmm. There are very few places where some stochastic behavior is expected (like placing mutations on the children of the root). Some variation might also come from rounding behavior, but on the same machine I'd expect these to be the same on every run. I am not sure whether any underlying optimization routine might use their own RNG.

@ktmeaton
Copy link
Contributor Author

Thanks for your reply! The variation I notice has been node dates (both joint and marginal). I'll play around with the parameters and see if I figure out anything more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants