def centroid(vertsList):
    """
    This function returns the baricenter of a set of Blender vertices,
    returning a coordinate vector formatted as a float list
    [float X,float Y, float Z].
    This is the sum of all of the vectors divided by the number of vectors.

    Parameters
    ----------

    vertsList:
        List of Blender meshvertex objects.
    """
    nVerts = len(vertsList)
    xTot = 0.0; yTot = 0.0; zTot = 0.0
    for v in vertsList:
        xTot += v.co[0]
        yTot += v.co[1]
        zTot += v.co[2]
    if nVerts != 0:
        centrX = xTot/nVerts
        centrY = yTot/nVerts
        centrZ = zTot/nVerts
    else:
        print("Warning: no verts to calc centroid")
        return [0,0,0]
    return [centrX,centrY,centrZ]