Graphics | ![]() ![]() |
Plotting Markers and Lines
To plot both markers and the lines that connect them, specify a line style and a marker type. For example, the following command plots the data as a red, solid line and then adds circular markers with black edges at each data point.
x = 0:pi/15:4*pi; y = exp(2*cos(x));plot(x,y,'
-r',x,y,'ok')
![]() | Plotting Only the Data Points | Line Styles for Black and White Output | ![]() |