clusterDBSCAN.plot
Description
Examples
Cluster Detections in Range and Doppler
Create detections of extended objects with measurements in range and Doppler. Assume the maximum unambiguous range is 20 m and the unambiguous Doppler span extends from Hz to Hz. Data for this example is contained in the dataClusterDBSCAN.mat
file. The first column of the data matrix represents range, and the second column represents Doppler.
The input data contains the following extended targets and false alarms:
an unambiguous target located at
an ambiguous target in Doppler located at
an ambiguous target in range located at
an ambiguous target in range and Doppler located at
5 false alarms
Create a clusterDBSCAN
object and specify that disambiguation is not performed by setting EnableDisambiguation
to false
. Solve for the cluster indices.
load('dataClusterDBSCAN.mat'); cluster1 = clusterDBSCAN('MinNumPoints',3,'Epsilon',2, ... 'EnableDisambiguation',false); idx = cluster1(x);
Use the clusterDBSCAN
plot
object function to display the clusters.
plot(cluster1,x,idx)
The plot indicates that there are eight apparent clusters and six noise points. The 'Dimension 1'
label corresponds to range and the 'Dimension 2'
label corresponds to Doppler.
Next, create another clusterDBSCAN
object and set EnableDisambiguation
to true
to specify that clustering is performed across the range and Doppler ambiguity boundaries.
cluster2 = clusterDBSCAN('MinNumPoints',3,'Epsilon',2, ... 'EnableDisambiguation',true,'AmbiguousDimension',[1 2]);
Perform the clustering using ambiguity limits and then plot the clustering results. The DBSCAN clustering results correctly show four clusters and five noise points. For example, the points at ranges close to zero are clustered with points near 20 m because the maximum unambiguous range is 20 m.
amblims = [0 maxRange; minDoppler maxDoppler]; idx = cluster2(x,amblims); plot(cluster2,x,idx)
Input Arguments
clusterer
— Clusterer object
clusterDBSCAN
object
Clusterer object, specified as a clusterDBSCAN
object.
X
— Input data to cluster
real-valued N-by-P matrix
Input data, specified as a real-valued N-by-P matrix. The N rows correspond to points in a P-dimensional feature space. The P columns contain the values of the features over which clustering takes place. For example, a two-column input can contain Cartesian coordinates x and y, or range and Doppler.
Data Types: double
idx
— Cluster indices
N-by-1 integer-valued column vector
Cluster indices, specified as an N-by-1 integer-valued column
vector. Cluster indices represent the clustering results of the DBSCAN algorithm
contained in the first output argument of clusterDBSCAN
.
idx
values start at one and are consecutively numbered. The plot
object function labels each cluster with the cluster index. A value of –1 in
idx
indicates a DBSCAN noise point. Noise points are not
labeled.
Data Types: double
ax
— Axes of plot
Axes
handle
Axes of plot, specified as an Axes
object handle.
Data Types: double
titlestr
— Plot title
character vector | string
Plot title, specified as a character vector or string.
Example: 'Range-Doppler Clusters'
Data Types: char
| string
Output Arguments
fh
— Figure handle of plot
positive scalar
Figure handle of plot, returned as a positive scalar.
Version History
Introduced in R2021a
MATLAB-Befehl
Sie haben auf einen Link geklickt, der diesem MATLAB-Befehl entspricht:
Führen Sie den Befehl durch Eingabe in das MATLAB-Befehlsfenster aus. Webbrowser unterstützen keine MATLAB-Befehle.
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)