File: nonParametricDiffData.sci

package info (click to toggle)
scilab-plotlib 0.41-2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 3,196 kB
  • sloc: xml: 3,308; makefile: 15
file content (11 lines) | stat: -rw-r--r-- 274 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
function [zx,zy]=nonParametricDiffData(x,y,Z);

nx=length(x);
ny=length(y);

zx=(Z(:,2:$)-Z(:,1:$-1))*sparse([1:nx-1;1:nx-1]',1../(x(2:$)-x(1:$-1)));
zy=sparse([1:ny-1;1:ny-1]',1../(y(2:$)-y(1:$-1)))*(Z(2:$,:)-Z(1:$-1,:));

zx(:,$+1)=zx(:,$);
zy($+1,:)=zy($,:);
endfunction