Skip to content

Commit

Permalink
adding in factor of two in catalog
Browse files Browse the repository at this point in the history
  • Loading branch information
clararehmann committed Jan 22, 2025
1 parent d0d8076 commit 21940b0
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions stdpopsim/catalog/DroMel/dfes.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,20 +29,24 @@ def _HuberDFE():
]
neutral = stdpopsim.MutationType()
gamma_shape = 0.33 # shape
gamma_mean = -3.96e-04 # expected value
gamma_scale = 1.2e-3 # scale
gamma_mean = gamma_shape * gamma_scale # expected value
h = 0.5 # dominance coefficient
negative = stdpopsim.MutationType(
dominance_coeff=h,
distribution_type="g", # gamma distribution
distribution_args=[gamma_mean, gamma_shape],
# (1+s for homozygote in SLiM versus 1+2s in dadi)
distribution_args=[-2 * gamma_mean, gamma_shape],
)

# LNS = 2.85 * LS
# prop_synonymous = 1/(1+2.85) = 0.26
prop_synonymous = 0.26
return stdpopsim.DFE(
id=id,
description=description,
long_description=long_description,
mutation_types=[neutral, negative],
proportions=[0.26, 0.74], # LNS = 2.85 x LS
proportions=[prop_synonymous, 1 - prop_synonymous], # LNS = 2.85 x LS
citations=citations,
)

Expand Down

0 comments on commit 21940b0

Please sign in to comment.