any.sci
来自「小波分解源代码」· SCI 代码 · 共 20 行
SCI
20 行
function T=any(s)
//ANY True if any element of a vector is nonzero.
// For vectors, ANY(V) returns 1 if any of the elements of the
// vector are non-zero. Otherwise it returns 0. For matrices,
// ANY(X) operates on the columns of X, returning a row vector
// of 1's and 0's. For N-D arrays, ANY(X) operates on the first
// non-singleton dimension.
//
// ANY(X,DIM) works down the dimension DIM. For example, ANY(X,1)
// works down the first dimension (the rows) of X.
// Copyright Aldo I Maalouf
if s==zeros(s);
T=0;
else
T=1;
end
endfunction
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?