def linear_probability(sims, slope, intercept):
    """Calculate linear transformation, capped at 0 an 1."""
    
    if slope < 0:
        Warning(f"Slope parameter is negative: {slope}")
    if intercept < 0:
        Warning(f"Intercept parameter is negative {intercept}")
        
    return (slope*sims + intercept).clip(0, 1)