Return a vector of row numbers of points that have nearest center angle

nstP(z1, z2)

Arguments

z1

a data frame or a matrix of xy coordinates of a tree ring (usualy inner ring)

z2

a data frame or a matrix of xy coordinates of a tree ring (usualy outer ring)

Value

a vector of row numbers of z2, the length is nrow(z1)

Examples

L_out<-TR@L[[1]];L_in<-TR@L[[30]]
np<-nstP(L_out,L_in)
plot(L_out,col="red"); points(L_in)
segments(L_out[,1],L_out[,2],L_in[np,1],L_in[np,2],col="blue")