from typing import List
import statistics


def znormalizeData(valList: List[float]) -> List[float]:
    """
    Given a list of floats, return the z-normalized values of the floats

    The formula is: z(v) = (v - mean) / stdDev
    In effect, this scales all values to the range [-4, 4].
    It can be used, for example, to compare the pitch values of different speakers who
    naturally have different pitch ranges.
    """
    valList = valList[:]
    meanVal = statistics.mean(valList)
    stdDevVal = statistics.stdev(valList)

    return [(val - meanVal) / stdDevVal for val in valList]