Presentation style of points
MuPAD® notebooks are not recommended. Use MATLAB® live scripts instead.
MATLAB live scripts support most MuPAD functionality, though there are some differences. For more information, see Convert MuPAD Notebooks to MATLAB Live Scripts.
|Objects||PointStyle Default Values|
PointStyle determines the presentation style
of points. The various styles are demonstrated in Example 1.
In 3D, only two styles
supported by the renderer.
Many graphical objects such as curves, surfaces etc. are approximated
by a numerical mesh. With
the points of this mesh become visible. These points react to
PointStyle cannot be animated.
We plot 2D points in all available styles:
styles := [Circles, FilledCircles, Crosses, XCrosses, Diamonds, FilledDiamonds, Squares, FilledSquares, Stars]: points := null(): for i from 1 to nops(styles) do points := points, plot::Point2d([i, i], PointStyle = styles[i], Title = expr2text(styles[i]), TitlePosition = [i + 0.3, i - 0.15]): end_for: plot(points, PointSize = 3*unit::mm, Axes = None, TitleAlignment = Left):
delete styles, points, i:
In 3D, the renderer only supports the point styles
plot(plot::Point3d([-1, -1, 0], PointStyle = FilledCircles, Title = "FilledCircles", TitlePosition = [-1, -0.8, 0]), plot::Point3d([1, 1, 0], PointStyle = FilledSquares, Title = "FilledSquares", TitlePosition = [1, 1.2, 0]), PointSize = 3*unit::mm, ViewingBox = [-2..2, -2..2, 0..1], CameraDirection = [0, -1, 1000]):
We can access the
PointStyle attribute from
a point and change it:
p := plot::Point2d(1, 2): p::PointStyle := Diamonds: p::PointStyle