Creates a new visual style
    
    :param title: title of the visual style
    :param defaults: a list of dictionaries for each visualProperty
    :param mappings: a list of dictionaries for each visualProperty
    :param host: cytoscape host address, default=cytoscape_host
    :param port: cytoscape port, default=1234
    
    :retunrs: nothing

def create_styles(title,defaults=None,mappings=None,host=cytoscape_host,port=cytoscape_port):
    """
    Creates a new visual style
    
    :param title: title of the visual style
    :param defaults: a list of dictionaries for each visualProperty
    :param mappings: a list of dictionaries for each visualProperty
    :param host: cytoscape host address, default=cytoscape_host
    :param port: cytoscape port, default=1234
    
    :retunrs: nothing
    """   
    
    if defaults:
        defaults_=[]
        for d in defaults:
            if d:
                defaults_.append(d)
        defaults=defaults_

    if mappings:
        mappings_=[]
        for m in mappings:
            if m:
                mappings_.append(m)
        mappings=mappings_

    try:
        update_style(title,defaults=defaults,mappings=mappings,host=host,port=port)
        print("Existing style was updated.")
        sys.stdout.flush()
    except:
        print("Creating new style.")
        sys.stdout.flush()
        URL="http://"+str(host)+":"+str(port)+"/v1/styles"
        PARAMS={"title":title,\
               "defaults":defaults,\
               "mappings":mappings}
        r = requests.post(url = URL, json = PARAMS)
        CheckResponse(r)