<s> import matplotlib . pyplot as plt <EOL> from sklearn . datasets . samples_generator import make_blobs <EOL> from sklearn . cluster import KMeans <EOL> def plot_kmeans ( ) : <EOL> X , y = make_blobs ( n_samples = <NUM_LIT> , centers = <NUM_LIT:4> , <EOL> random_state = <NUM_LIT:0> , cluster_std = <NUM_LIT> ) <EOL> y_pred = KMeans ( <NUM_LIT:4> ) . fit ( X ) . predict ( X ) <EOL> fig , ax = plt . subplots ( <NUM_LIT:1> , <NUM_LIT:2> , figsize = ( <NUM_LIT:12> , <NUM_LIT:6> ) ) <EOL> ax [ <NUM_LIT:0> ] . scatter ( X [ : , <NUM_LIT:0> ] , X [ : , <NUM_LIT:1> ] ) <EOL> ax [ <NUM_LIT:0> ] . set_title ( '<STR_LIT>' ) <EOL> ax [ <NUM_LIT:1> ] . scatter ( X [ : , <NUM_LIT:0> ] , X [ : , <NUM_LIT:1> ] , c = y ) <EOL> ax [ <NUM_LIT:1> ] . set_title ( '<STR_LIT>' ) </s>
