文件名称:csum
介绍说明--下载内容均来自于网络,请自行研究使用
对有缺测的数据求和
用法:
y=csum(x,k,c)
x为有缺测的数据,如仪器观测数据
k为对第几维求和
c为控制条件,如c为50,表示有50个以上的观测时才求和,否则为nan;如c为-5,表示缺测在5次以下才求和,否则nan-calculate the statistical sum of data but tick off nan
Usage:
y=csum(x,|k) or y=csum(x,k,|c), k can be []
[m,n,...]=size(x)
if k==1, [1,n,...]=size(y)
if not set k, then k=1, but if m==1, k=k+1,>>...
if k==2, [m,1,...]=size(y)
if k>2, [m,n,...,1(k demension),...]=size(y).
you can squeeze(y) by yourself to remove the dim(whose size(y,dim)==1)
c can control output to be nan ro sum, c = 0 by default(namely, not work)
if c>0, if valuable numbers(notnan) < c, then output nan instead of sum
if c<0, if nan numbers >= c, then output nan instead of sum
用法:
y=csum(x,k,c)
x为有缺测的数据,如仪器观测数据
k为对第几维求和
c为控制条件,如c为50,表示有50个以上的观测时才求和,否则为nan;如c为-5,表示缺测在5次以下才求和,否则nan-calculate the statistical sum of data but tick off nan
Usage:
y=csum(x,|k) or y=csum(x,k,|c), k can be []
[m,n,...]=size(x)
if k==1, [1,n,...]=size(y)
if not set k, then k=1, but if m==1, k=k+1,>>...
if k==2, [m,1,...]=size(y)
if k>2, [m,n,...,1(k demension),...]=size(y).
you can squeeze(y) by yourself to remove the dim(whose size(y,dim)==1)
c can control output to be nan ro sum, c = 0 by default(namely, not work)
if c>0, if valuable numbers(notnan) < c, then output nan instead of sum
if c<0, if nan numbers >= c, then output nan instead of sum
(系统自动生成,下载前可以参看下载内容)
下载文件列表
csum.m