图形
T = 1000;
A=0.7;
h=[];
Y=总和(sqrt(0.05)。*randn(T,1));
X=(1:T)。/T;
I=查找(X>A);
(我)= Y(我(1));
h(1) =情节(X, Y,“- k”,“线宽”2);
持有在
dims=get(gca,“ylim”);
yy = linspace (dim (1), (2) dim, 100);
xx=repmat(A,1100);
h(2) =情节(xx, yy,“:r”,“线宽”2);
dims=get(gca,“xlim”);
xx = linspace (dim (1), (2) dim . *, 100);
yy=repmat(Y(I(1)),1100);
h(3) =情节(xx, yy,“b”,“线宽”2);
网格在
G =传奇(h,“粒子运动”,“停止点”,“停止值”);
集(G,“位置”,“最好的”,“翻译”,“乳胶”);