You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This isn't something that we support in msprime, but there is a new tsconvert repo in development which is intended to do all of these types of conversions between formats. Unfortunately tsconvert hasn't been released and is pretty incomplete. There is a ts_ms function which might be useful to you though.
Hi @jeromekelleher. Regarding the answer above, I see the last commit to tsconvert was 17 months ago; is it still considered an active project or has it been abandoned? I just got another SLiM user today who wants to get MS output from a tree sequence; this comes up with some regularity. This would really not be hard to add to the Python APIs, would it? It's a very simple format; it'd be nice to have a better solution for this.
Yeah, this is a pretty simple thing to do and we should just do it in tskit. I guess we can just thrown an error if we hit a situation where ms-format doesn't make sense.
We haven't abandoned tsconvert, as such, just nobody has done any work on it! ;)
Ability to output in ms format is very much anticipated function. This can make tons of old scripts and pipelines usable. Would be great if someone can add this ms-format output?
Hi,
I'm working on a function to write out ms format output from tree sequence, creating a function similar to the existing write_vcf function. Hope this approach is fine.
Say, @yunusbb and @SBNoor - @saurabhbelsare is working on this over in #854, and we'd like to make sure this would do what you need for your pipelines. Care to elaborate what sort of ms format you use? e.g. do you get the newick trees (with -T)? is num_replicates > 1?
Activity
jeromekelleher commentedon May 20, 2019
This isn't something that we support in msprime, but there is a new tsconvert repo in development which is intended to do all of these types of conversions between formats. Unfortunately tsconvert hasn't been released and is pretty incomplete. There is a ts_ms function which might be useful to you though.
bhaller commentedon Jul 20, 2020
Hi @jeromekelleher. Regarding the answer above, I see the last commit to tsconvert was 17 months ago; is it still considered an active project or has it been abandoned? I just got another SLiM user today who wants to get MS output from a tree sequence; this comes up with some regularity. This would really not be hard to add to the Python APIs, would it? It's a very simple format; it'd be nice to have a better solution for this.
jeromekelleher commentedon Jul 20, 2020
Yeah, this is a pretty simple thing to do and we should just do it in tskit. I guess we can just thrown an error if we hit a situation where ms-format doesn't make sense.
We haven't abandoned tsconvert, as such, just nobody has done any work on it! ;)
jeromekelleher commentedon Jul 20, 2020
Ah, this is a tskit issue. Moving it over there.
jeromekelleher commentedon Jul 20, 2020
Putting it into 0.3.0 for now, but we can push back to 0.3.1 if needs be.
yunusbb commentedon Aug 8, 2020
Ability to output in ms format is very much anticipated function. This can make tons of old scripts and pipelines usable. Would be great if someone can add this ms-format output?
saurabhbelsare commentedon Aug 19, 2020
Hi,
I'm working on a function to write out ms format output from tree sequence, creating a function similar to the existing write_vcf function. Hope this approach is fine.
jeromekelleher commentedon Aug 19, 2020
That would be excellent, thanks @saurabhbelsare!
yunusbb commentedon Aug 19, 2020
That would be a really useful function, thanks Saurabh!
petrelharp commentedon Sep 18, 2020
Say, @yunusbb and @SBNoor - @saurabhbelsare is working on this over in #854, and we'd like to make sure this would do what you need for your pipelines. Care to elaborate what sort of ms format you use? e.g. do you get the newick trees (with
-T)? isnum_replicates > 1?benjeffery commentedon Jun 5, 2025
Closing this as the method exists and #1464 exists to track documenting/moving the code.