#NEWLINE# def visualize_boundary_linear( X , y , model ) : #NEWLINE# #INDENT# visualize_data ( X , y ) #NEWLINE# if model : #NEWLINE# #INDENT# x1 = X [ : , 0 ] #NEWLINE# w = model . w #NEWLINE# b = model . b #NEWLINE# xp = np . linspace ( np . min ( x1 ) , np . max ( x1 ) , 100 ) #NEWLINE# yp = ( ( - ( ( w [ 0 ] * xp ) + b ) ) / w [ 1 ] ) #NEWLINE# plt . plot ( xp , yp ) #NEWLINE# #UNINDENT# plt . show ( )