search for: vspline

Displaying 1 result from an estimated 1 matches for "vspline".

Did you mean: spline
2010 Mar 12
1
Usage of apply function with two matrices
...and matrix V, which both have 3 columns and I want to create a spline function basing on coordinates from this matrices (more precisely coordinates of function nr 1: x are taken from Vf[,1] and y are taken from V[,1] respectively), because function apply() base on 1 argument I made it in this way: Vspline<-matrix(0,nrow=2*n,ncol=K) Vspline<-rbind(Vf[,1:3],V[,1:3]) where n=5000 and it is number of rows in V and Vf matrices and then: FV<-apply(Vspline,2, function(z) splinefun(Vspline[1:n,z],Vspline[(n+1):(2*n),z], method="mono",ties=mean)) The problems is, that when I am running...