stemdata.m

来自「很多matlab的源代码」· M 代码 · 共 21 行

M
21
字号
function stemdata(x,y,hLines)%STEMDATA Create stem plot data%   STEMDATA(x,y,hLines) changes the stem plot given by the handles%   in hLines to the new data x and y.%%   The input x and y should be equal length vectors.% Jordan Rosenthal, 5/4/98%          Revised, 1/20/99% Rajbabu, Revised, 11/19/2002  N = length(x);xx = zeros( 3*N, 1);yy = zeros( 3*N, 1);xx(1:3:end) = x;xx(2:3:end) = x;xx(3:3:end) = nan;yy(2:3:end) = y;yy(3:3:end) = nan;set(hLines(1:2),{'XData','YData'},{x y; xx yy});

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?