[R] number of analogs in significance test of MAT reconstructions using randomTF from palaeoSig

Jason Paul Joines jason at joines.org
Tue Oct 4 18:51:18 CEST 2011


     I'm trying to use the randomTF function from package palaeoSig to 
test the significance of a MAT reconstruction with nine analogs and a 
WA-PLS reconstruction with four components.  I'm probably missing 
something obvious here but how do I make sure that randomTF is testing 
the reconstruction based on the desired number of analogs / components?

     In:
fitmap.wapls = WAPLS( lumapspc, lumap)
sig.wapls = randomTF( spp = sqrt( lumapspc ), env = lumapenv, fos = 
sqrt( hcspc ), n = 999, fun = WAPLS, col = 4 )
     I assume "col = 4" tells randomTF to test the reconstruction based 
on the four component WA-PLS model as that's what the documentation 
seems to indicate.

     However, in:
fitmap.mat = MAT( lumapspc, lumap, dist.method = "chord", k = 20 )
sig.mat = randomTF( spp = lumapspc, env = lumapenv, fos = hcspc, n = 
999, fun = MAT, col = 9 )
     it seems that "col = 9" does not tell randomTF to test the 
reconstruction based on the 9 analog MAT model.  If I give col a value 
other than one or two, I get a "subscript out of bounds" error.  So I 
assume the col argument in this case selects between the mean and 
weighted mean predictions.
     If I pass additional arguments, k = 9 and dist.method = "chord" to 
randomTF, then the values of sig.mat$preds do not match the values 
obtained from:
predmap.mat = predict( fitmap.mat, hcspc, k = 9 )
     Also, if I give randomTF a k value less than 5, I get the error "k 
out of range".  So, passing k to randomTF must not be telling randomTF 
to use that number of analogs as I would not be able to select a four 
analog model.


Jason
===========



More information about the R-help mailing list