modelXYPlotWithImage

XY-plot with background image

Information

XY-plot with an image as background. The plot is visualized in the tools diagram view.

Special case

If the x and y vector contains only one data point a circle will be visualized instead of the polyline.

Coordinate transformation

The coordinate system of the diagram is built up by defining (x,y) values at two positions in the image, point_1 and point_2. For point_1 and point_2 the corresponding image pixel coordinates, point_1_imagePixelCoord and point_2_imagePixelCoord needs to be defined.


Image pixel dimension and coordinates of the specified image can be found by using an image program such as Paint.

Parameters

TypeNameDefaultDescription
Booleancircle_1_visibleif size(x, 1) == 1 then true else false
Image
StringimageName""Image name
Coordinate transformation
Real[2]point_1{0, 0}x,y value of point 1
Real[2]point_2{1, 1}x,y value of point 2
Real[2]point_1_imagePixelCoord{0, 500}Image pixel coordinate at point 1
Real[2]point_2_imagePixelCoord{1000, 0}Image pixel coordinate at point 2
RealimagePixelWidth1000Image pixel width
RealimagePixelHeight500Image pixel height
Diagram attributes
Integercolor{0, 0, 255}Color (RGB) for line 1

Components

TypeNameDefaultDescription
Real[:]x{(point_1[1] + point_2[1])/2}x-axis values
Real[size(x, 1)]y{(point_1[2] + point_2[2])/2}y-axis values
Realpoints_line
Realpoints_circle

Revisions