def data_value(value: str) -> float:
    """Convert to a float; some trigger values are strings, rather than
    numbers (ex. indicating the letter); convert these to 1.0."""
    if value:
        try:
            return float(value)
        except ValueError:
            return 1.0
    else:
        # empty string
        return 0.0