detectionPlotter
Description
creates a detection plotter for use with the theater plot detPlotter
= detectionPlotter(tp
)tp
.
creates a detection plotter with additional options specified by one or more
detPlotter
= detectionPlotter(tp
,Name,Value
)Name,Value
pair arguments.
Examples
Create and Update Detections for Theater Plot
Create a theater plot.
tp = theaterPlot('XLim',[0,90],'YLim',[-35,35],'ZLim',[1,10]);
Create a detection plotter with the name Radar Detections
.
radarPlotter = detectionPlotter(tp,'DisplayName','Radar Detections');
Update the detection plotter with three detections labeled 'R1'
, 'R2'
, and 'R3'
positioned in units of meters at , , and with corresponding velocities (in m/s) of , , and , respectively.
positions = [30, 5, 4; 30, -10, 2; 30, 15, 1]; velocities = [-10, 0, 2; -10, 3, 1; -10, -4, 1]; labels = {'R1','R2','R3'}; plotDetection(radarPlotter, positions, velocities, labels)
Input Arguments
tp
— Theater plot
theaterPlot
object
Theater plot, specified as a theaterPlot
object.
Name-Value Arguments
Specify optional pairs of arguments as
Name1=Value1,...,NameN=ValueN
, where Name
is
the argument name and Value
is the corresponding value.
Name-value arguments must appear after other arguments, but the order of the
pairs does not matter.
Before R2021a, use commas to separate each name and value, and enclose
Name
in quotes.
Example: 'MarkerSize',10
DisplayName
— Plot name to display in legend
character vector | string scalar
Plot name to display in legend, specified as the comma-separated pair consisting of 'DisplayName'
and a character vector or string scalar. If no name is specified, no entry is shown.
Example: 'DisplayName','Radar Detections'
HistoryDepth
— Number of previous updates to display
0 (default) | nonnegative integer less than or equal to 10,000
Number of previous track updates to display, specified as the comma-separated pair
consisting of 'HistoryDepth'
and a nonnegative integer less than or
equal to 10,000. If set to 0, then no previous updates are rendered.
Marker
— Marker symbol
'o'
(default) | character vector | string scalar
Marker symbol, specified as the comma-separated pair consisting of
'Marker'
and one of these symbols.
Marker | Description | Resulting Marker |
---|---|---|
"o" | Circle |
|
"+" | Plus sign |
|
"*" | Asterisk |
|
"." | Point |
|
"x" | Cross |
|
"_" | Horizontal line |
|
"|" | Vertical line |
|
"square" | Square |
|
"diamond" | Diamond |
|
"^" | Upward-pointing triangle |
|
"v" | Downward-pointing triangle |
|
">" | Right-pointing triangle |
|
"<" | Left-pointing triangle |
|
"pentagram" | Pentagram |
|
"hexagram" | Hexagram |
|
"none" | No markers | Not applicable |
MarkerSize
— Size of marker
6
(default) | positive integer
Size of marker, specified as the comma-separated pair consisting of
'MarkerSize'
and a positive integer in points.
MarkerEdgeColor
— Marker outline color
'black'
(default) | character vector | string scalar | RGB triplet | hexadecimal color code
Marker outline color, specified as the comma-separated pair consisting of
'MarkerEdgeColor'
and a character vector, a string scalar, an
RGB triplet, or a hexadecimal color code.
MarkerFaceColor
— Marker fill color
'none'
(default) | character vector | string scalar | RGB triplet | hexadecimal color code
Marker outline color, specified as the comma-separated pair consisting of
'MarkerFaceColor'
and a character vector, a string scalar, an
RGB triplet, a hexadecimal color code, or 'none'
. The default is
'none'
.
FontSize
— Font size for labeling platforms
10
(default) | positive integer
Font size for labeling detections, specified as the comma-separated pair
consisting of 'FontSize'
and a positive integer that represents
font point size.
LabelOffset
— Gap between label and positional point
[0 0 0]
(default) | three-element row vector
Gap between label and positional point it annotates, specified as the
comma-separated pair consisting of 'LabelOffset'
and a
three-element row vector. Specify the [x
y
z] offset in meters.
VelocityScaling
— Scale factor for magnitude length of velocity vectors
1
(default) | positive scalar
Scale factor for magnitude length of velocity vectors, specified as the
comma-separated pair consisting of 'VelocityScaling'
and a
positive scalar. The plot renders the magnitude vector value as VK,
where V is the magnitude of the velocity in meters per second, and
K is the value of VelocityScaling
.
Tag
— Tag to associate with the plotter
'PlotterN'
(default) | character vector | string scalar
Tag to associate with the plotter, specified as the comma-separated pair
consisting of 'Tag'
and a character vector or string scalar. The
default value is 'PlotterN'
, where
N is an integer that corresponds to the Nth
plotter associated with the theaterPlot
.
Tags provide a way to identify plotter objects, for example when searching using
findPlotter
.
Version History
Introduced in R2021a
See Also
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)