fdr.spatial2 {OLIN} | R Documentation

## Assessment of the significance of spatial bias

### Description

This function assesses the significance of spatial bias by a one-sided random permutation test. This is achieved by comparing the observed average values of logged fold-changes within a spot's spatial neighbourhood with an empirical distribution generated by random permutation. The significance of spatial bias is given by the false discovery rate.

### Usage

    fdr.spatial2(object,delta=2,N=100,av="median",edgeNA=FALSE)

### Arguments

`object` | object of class marrayRaw or marrayNorm
`delta` | integer determining the size of spot neighbourhoods (`(2*delta+1)x(2*delta+1)`).
`N` | number of random permutations performed for generation of empirical background distribution
`av` | averaging of `M` within neighbourhood by mean or median (default)
`edgeNA` | treatment of edges of array: For `edgeNA=TRUE`, the significance of a neighbourhood (defined by a sliding window) is set to NA, if the neighbourhood extends over the edges of the matrix.

### Details

The function `fdr.spatial2.Rd` is basically the same as `fdr.spatial`, but differs in its input and output formats. Details about the functionality can be found at `fdr.spatial`.

### Value

Two list of vectors containing the false discovery rates for positive (`FDRp`) and negative (`FDRn`) deviations of median/mean of \code{M} of the spot's neighbourhood is produced. Each vector contains the false discovery values for one array.

### Note

This function will be fused with `fdr.spatial` in future versions using S4-style methods.

### Author(s)

Matthias E. Futschik (http://itb.biologie.hu-berlin.de/~futschik)

### See Also

`p.spatial`, `fdr.int`, `sigxy.plot`,

### Examples

    # To run these examples, delete the comment signs before the commands.
    #
    # LOADING DATA
    # data(sw)
    #
    # CALCULATION OF SIGNIFICANCE OF SPOT NEIGHBOURHOODS
    # For this illustration, N was chosen rather small. For "real" analysis, it should be larger.
    # FDR <- fdr.spatial2(sw,delta=2,N=10,av="median",edgeNA=TRUE)
    #
    # SIGNIFICANCE PLOTS OF ARRAY 1
    # sigxy.plot2(sw[,1],FDR$FDRp[[1]],FDR$FDRn[[1]],color.lim=c(-5,5),main="FDR")
    # SIGNIFICANCE PLOTS OF ARRAY 3
    # sigxy.plot2(sw[,3],FDR$FDRp[[3]],FDR$FDRn[[3]],color.lim=c(-5,5),main="FDR")
    #

[Package OLIN version 1.62.0 Index]