Skip to content

Commit

Permalink
add dfes.py configuration file
Browse files Browse the repository at this point in the history
  • Loading branch information
peterdfields committed Mar 21, 2024
1 parent fbb94c2 commit da41e30
Showing 1 changed file with 51 additions and 0 deletions.
51 changes: 51 additions & 0 deletions stdpopsim/catalog/MusMus/dfes.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
import stdpopsim

_species = stdpopsim.get_species("MusMus")

###########################################################
#
# DFEs
#
###########################################################


def _BookerDFE():
id = "Gamma_Booker2021_CDS"
description = "Deleterious Gamma DFE CDS"
long_description = """
Return negative MutationType()s representing a Mus
musculus subsp. castaneous DFE for protein coded exons or CDS. Booker et al. (2021),
https://doi.org/10.1101/2021.06.10.447924
DFE parameters are based on an analysis of the unfolded site frequency spectrum
(uSFS) using polyDFE v2 (Tataru and Bataillon 2019) as presented in Booker
et al. (2021).
"""
citations = [
stdpopsim.Citation(
author="Booker et al.",
year=2021,
doi="https://doi.org/10.1101/2021.06.10.447924",
reasons={stdpopsim.CiteReason.DFE}, # include the dfe_model reason
)
]
neutral = stdpopsim.MutationType()
gamma_shape = 0.186 # shape
gamma_mean = -5.96e-02 # expected value
h = 0.5 # dominance coefficient
negative = stdpopsim.MutationType(
dominance_coeff=h,
distribution_type="g", # gamma distribution
distribution_args=[gamma_mean, gamma_shape],
)

return stdpopsim.DFE(
id=id,
description=description,
long_description=long_description,
mutation_types=[neutral, negative],
proportions=[0.333, 0.664],
citations=citations,
)


_species.add_dfe(_BookerDFE())

0 comments on commit da41e30

Please sign in to comment.