Modeling Missing Data

HMC doesn’t like discontinuity ; so I reckon your IF statement in the signal function is part of your problem.

You can use an inverse logit to make the transition between your two densities continuous. This thread uses the trick:

3 Likes