def _parse_value_input(string, allow=[]):
    """
    Parses leftmost panel input to detect ranges of values or single values.
    Returns either a double or a list of doubles.
    """
    a = string
    
    # remove brackets
    rm = ['(', ')', '[', ']']
    for s in rm:
        if s not in allow:
            a = a.replace(s,'')
    
    # replace commas with space
    a = a.replace(',',' ')
    
    #split string on spaces
    a = a.split(' ')
    
    # attempt conversion to float (most data types are numeric)
    try:
        b = [float(v) for v in a if v != '']
    except ValueError:
        b = [str(v) for v in a if v!= '']
    
    # remove list structure from single entries
    if len(b) == 1:
        b = b[0]
    
    return b