Skip to content

annotate_mutations #103

Open
Open

Description

@petrelharp

To allow msprime to add nucleotide mutations, we could (a) use msprime to add nucleotide mutations, and then (b) convert these to SLiM nucleotide mutations. To do this, we'd need a pyslim method (pyslim.annotate_nucleotide_mutations?) that assigns SLiM IDs and moves the nucleotide itself from derived state to metadata.

Maybe this should be just part of a more general function (pyslim.annotate_mutations) that would do other modifications to the mutation metadata, like drawing selection cofficients from some distribution.

Activity

  1. bhaller commented on Sep 16, 2020

    @bhaller
    Collaborator

    This sounds reasonable. My only comment, really, is a big one: it's a shame that mutations in msprime and SLiM are in such completely different worlds. That they follow completely different paradigms, are represented in completely different ways, etc. It puts pyslim in a rather difficult position, although so far it seems to be working surprisingly well. I guess there is no solution to this, really, since both SLiM and msprime seem like they're pretty committed to their respective approaches, and changing either one would mean massive breakage and loss of backward compatibility. But it is nevertheless a shame, and I wonder whether there's some big-picture rethink that would improve things. Some way of bringing both paradigms together under a single unifying umbrella, or something.

  2. petrelharp commented on Sep 16, 2020

    @petrelharp
    ContributorAuthor

    Well, tskit's model is really just SLiM's "last" stacking policy. It's the "stack" policy that's different. If SLiM was always on "stack" mode then I might suggest having tskit use that mode optinonally also (ie, treat a node's genotype as "all mutations above it" instead of "most recent mutation above it"). But given that SLiM does both, and also more complicated things, I think the way it is is Pretty Good.

  3. added this to the v1.0 milestone on Mar 10, 2021
  4. modified the milestones: v1.0, v1.1 on Dec 15, 2021
  5. added
    enhancement
    on Aug 10, 2022
  6. modified the milestones: v1.0, v1.1 on Aug 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancement

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions