(inertia_stor, base_clusters)
return img
plotting function that generates the elbow graph

    :param base_clusters: number of clusters you begin testing at
    :param inertia_stor: the array of inertia values
    :return the elbow graph
plotting function that generates the elbow graph
plotting function that generates the elbow graph
def elbow_cluster_graph(inertia_stor, base_clusters):
    '''
    plotting function that generates the elbow graph

    :param base_clusters: number of clusters you begin testing at
    :param inertia_stor: the array of inertia values
    :return the elbow graph
    '''
    ranged = [i+1 for i in range(base_clusters, len(inertia_stor) + base_clusters)]

    img = plt.figure()
    plt.plot(ranged, inertia_stor, marker='o')
    # plt.plot(inertia_stor)
    plt.title('Elbow Graph for Clustering')
    plt.ylabel('SSE/Inertia')
    plt.xlabel('Number of Clusters')
    return img
def elbow_cluster_graph ( inertia_stor , base_clusters ) : ranged = [ i + 1 for i in range ( base_clusters , len ( inertia_stor ) + base_clusters ) ] img = plt . figure ( ) plt . plot ( ranged , inertia_stor , marker = 'o' ) # plt.plot(inertia_stor) plt . title ( 'Elbow Graph for Clustering' ) plt . ylabel ( 'SSE/Inertia' ) plt . xlabel ( 'Number of Clusters' ) return img