Dear Jerome,
Thank you very much for your response. Is there a quick work-around with the fix as I am attending to a review comment on my paper?
Alternatively, I have been trying to use the code from the tutorial as below but does not print to the screen for me. Is there a way I can make this save it into a file. I tried to introduce additional option in the second code far below but still did not save for me. Could you help me look into this code. Thank you.
import msprime
tree_sequence = msprime.simulate(sample_size=6, Ne=1000, length=1e4, recombination_rate=2e-8)
for tree in tree_sequence.trees():
print("-" * 20)
print("tree {}: interval = {}".format(tree.index, tree.interval))
print(tree.draw(format="unicode"))
import msprime
my_file=open("treefile", "w")
tree_sequence = msprime.simulate(sample_size=6, Ne=1000, length=1e4, recombination_rate=2e-8)
for tree in tree_sequence.trees():
print("-" * 20)
print("tree {}: interval = {}".format(tree.index, tree.interval))
print(tree.draw(format="unicode"))
my_file.write(tree.draw(format="unicode")
my_file.close()
You received this message because you are subscribed to a topic in the Google Groups "msprime-users" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/msprime-users/UqGZVPZpROA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
msprime-user...@googlegroups.com.
To view this discussion on the web, visit
https://groups.google.com/d/msgid/msprime-users/adbfbfa5-c65a-1ebf-da0c-ade78d9fe772%40ndm.ox.ac.uk.