Bisquare function

bisquare function

The model term bis(X,Y,s) forms basis functions from the coordinants in variables X and Y according to the bisquare function with grid spacing defined by s. It assumes X and Y are measured in the same units, and calculates the base grid step size as ((range of X)+(range of Y))/s. Thus, the distance between the grid points is controlled by the optional parameter s which has a default value of 15 and can be set between 5 and 100. (If a value greater than 100 is specified, it is divided by 10 until less than 100. Thus to get a grid based on dividing the range by 33.33, set s as 3333.) For example, if the values of X range (say) 3.65 to 5.62 and of Y range (say) 6.42 to 7.89, and with s=16, the grid step size is S=( 5.62 - 3.65 + 7.89 - 6.42)/16 = 3.44/16=.215. Based on this grid step size, we create a grid of points that overlay the coordinate space, extending just past the extreme points and centred on the means of X (say 4.78) and Y (say 7.05) as follows.
       XB=NINT((XMIN-XMEAN)/STEP -2)*STEP+XMEAN;
       NX=(XMAX-XB)/STEP+1
So, for the example,
XB=NINT((3.65-4.78)/0.215-2)*0.215+4.78
= -7*0.215+4.78= 3.275, NX=INT(5.62-3.275)/0.215)+1=11. Thus for the X direction, there are 11 steps running
XB+1S XB+2S ... XB+11S: 3.490, 3.705 ... 4.78, ..., 5.640. for Y, there are 8 steps running 6.405, ... 7.05, ... 7.91. For the Level 1 basis functions, define R1=1.5S and for observations closer than R1 to a particular grid point, the basis function has a value (1-d2/R21) and zero otherwise; d is the euclidean distance of the observation from the grid point. We then define another two grids with a third and a ninth the density in both directions, coincident with the base grid. These have range values of R2=4.5S and R3=13.5S and basis functions are created for them as well. The bisquare function relative to each of these grid points is (1-MAX(d2/Ri2,1))2.

These details are reported in the .res file in the form (from the example in the next section):
 Setup for model term bis(X,Y,16)
 Bisquare design grid Min Mean Max of X  3.6362      4.7837      5.6216
  11 points:   3.4792      3.6966     ...   5.6534
 Step 3 and Step 9 grids coincide at base grid point   1
 Bisquare design grid Min Mean Max of Y  6.4189      7.0536      7.9122
   8 points:   6.4013      6.6188     ...   7.9233
 Step 3 and Step 9 grids coincide at base grid point   4
 There are therefore  88 Level 1 basis functions (11x8)
                        12 Level 2 basis functions (4x3)
                         2 Level 3 basis functions (2x1); Total  102
 although some may be null if there are no actual data points
 near the grid points.  The bisquare basis function is
 (1-MAX(D2/R2,1))2 where D2 is the squared euclidean distance
 from the data point to the grid point, and R2 is ( 0.21741    *r)2
 and r is 1.5, 4.5 or 13.5 for level 1, 2 or 3 respectively.
The bis() model term therefore actually generates 3 sets of basis functions which allow modelling of the spatial variation at three levels. Since the exact number of levels in each dimension at each level will not be known in advance, it will generally be necessary to run with the default (IDV) structure for the initial run, to generate this information (and get an initial variance component for the scale of these effects). However, this IDV model is unlikely to be optimal. At the least, we want separate variances for each level. For the lower levels (larger number of basis functions), an AR model in each direction sounds plausible. Otherwise, coruv() may be suitable, or just idv(). % For the example (in the next section), the following was used:
 log(TC,160) ~ mu X Y Field*Session Elev  !r  fac(X,Y) .3 ,
 !{ ar1v(12,0.1,0.2).ar1(10) coruv(16,.1,.1) idv(2) .1 bis(X,Y,16) !}
The first line shows analysis of a transformed form of the response variable, TC, and a fixed model. In this example, there were some duplicate readings so we can separate a true residual from a spatial lack of fit ( fac(X,Y)). Our focus here is on the second line which defines separate variance structures for the three levels of basis functions generated by bis(X,Y,16). The first level consisted of 88 variables in a 11 cross 8 array to which we have fitted an AR1 AR1 correlation structure. In ar1v(11,0.1,0.2), ar1v() specifies a first order autoregressive correlation structu with a scale parameter, 11 says it is of dimension 11, 0.1 is an initial value of the correlation parameter, . 0.2 is an initial value of the scale (variance) parameter. Similarly, ar1(8) defines an autogressive structure without a scale parameter for the other dimension (the default initial correlation parameter value is 0.1). The second level has 12 variables in a 4 cross 3 arrangement and this model says treat them as exchangable with a common correlation and equal variance. For the third level with 2 variables in a 2 cross 1 arrangement, we have just specified independent effects.

See Also

Return to index