[R] Permutation test with raster data

Rolf Turner r.turner at auckland.ac.nz
Sat Jan 4 01:19:44 CET 2014


See in-line below.

	cheers,

	Rolf Turner

On 04/01/14 12:48, Stefan Mühlbauer wrote:
> Hello!
> Â
> I am having two variables x and y (whereas y is a set of raster images) and want to
> quantify the correlation between x and y by calculating the Pearson
> Correlation Coefficient. In order to ensure how signficant the correlation
> results are, I am interested in getting the p-value (<0.1) for this two
> tailed student-t distribution. The problem now is: I have a very small
> number of observations and therefore would need to make a permutation test,
> which enables to simulate a high number of observations.

	You are deluding yourself.
> Â
> So far I did  the Pearsons Correlation and Significance test, but without
> applying permutaton test. I used following formula for obtaining the
> p-values:
> Â
> T = r*(sqrt(n-2))/sqrt(1-r²)
> p-value = 2 P [ T(n-2) ≥ |t|]
> r...Pearson correlation coefficient
> n...degree of freedom
> Â
> Now I have to redo everything using a permutation test. I thought of implementing 'lmp' function in 'calc' function of raster package.
> The two variables I wanted to save within two lists. I am interested in getting the p-value for each pixel. Can this work?
> Â
> I will very much appreaciate your help!




More information about the R-help mailing list