MATLAB-在一个区域内生成一个cluster
作者:互联网
clc,clear all,close all
MU1 = [-0.25 -1];
SIGMA1 = [0.04 0; 0 0.04];
MU2 = [0.25 1];
SIGMA2 = [0.04 0; 0 0.04];
MU3 = [-1 0.25];
SIGMA3 = [0.04 0; 0 0.04];
MU4 = [1 -0.25];
SIGMA4 = [0.04 0; 0 0.04];
X = [mvnrnd(MU1,SIGMA1,300);mvnrnd(MU2,SIGMA2,300)];
Y = [mvnrnd(MU3,SIGMA3,300);mvnrnd(MU4,SIGMA4,300)];
scatter(Y(:,1),Y(:,2),10,'.')
hold on
scatter(X(:,1),X(:,2),10,'.')
xlim([-1.5 1.5])
ylim([-1.5 1.5])
xlabel('同相幅度')
ylabel('正交幅度')
title('散点图')
标签:1.5,mvnrnd,300,0.25,0.04,生成,cluster,MATLAB,SIGMA4 来源: https://www.cnblogs.com/jgg54335/p/15510210.html