Repository navigation
Error in sim_mutations: "AttributeError: 'generator' object has no attribute 'tables'" #2029
Answered
by
alanrogers
alanrogers
asked this question in
Q&A
|
I'm trying to move to the 1.x API for msprime and am getting the following error from sim_mutations: Would be grateful for suggestions. My code is below: |
Answered by
alanrogers
Apr 4, 2022
Replies: 1 comment 11 replies
|
I think I found an anwer to my own question. When sim_ancestry is called without num_replicates, it returns a value of type But when it's called with num_replicates, it returns a value of type generator: sim_mutations wants a value of the former type, not a generator. |
11 replies
Answer selected by
alanrogers
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I think I found an anwer to my own question. When sim_ancestry is called without num_replicates, it returns a value of type
tskit.trees.TreeSequence:But when it's called with num_replicates, it returns a value of type generator:
sim_mutations wants a value of the former type, not a generator.