Description Usage Arguments Details Value

View source: R/F_getTestStats.R

A function to calculate observed and permuation z-statistics on a n-by-p matrix of observations

1 2 3 4 5 6 7 8 9 10 11 | ```
getTestStats(
Y,
center,
test = "wilcox.test",
x,
B,
argList,
tieBreakRan,
replace,
scale
)
``` |

`Y` |
The nxp data matrix |

`center` |
a boolean, should data be centered prior to permuation |

`test` |
A function name, possibly user defined. See details. |

`x` |
A vector defining the groups. Will be coerced to factor. |

`B` |
an integer, the number of permuations |

`argList` |
A list of further arguments passed on to the test function |

`tieBreakRan` |
A boolean, should ties of permutation test statistics be broken randomly? If not, midranks are used |

`replace` |
A boolean. If FALSE, samples are permuted (resampled without replacement), if TRUE the samples are bootstrapped (resampled with replacement) |

`scale` |
a boolean, should data be scaled prior to resampling |

For test "wilcox.test" and "t.test", fast custom implementations are used. Other functions can be supplied but must accept a y outcome variable, a x as grouping variable, and possibly a list of other arguments. It must return all arguments needed to evaluate its quantile function if z-values are to be used.

A list with components

`statObs` |
A vector of length p of observed test statistics |

`statsPerm` |
A p-by-B matrix of permutation test statistics |

`resamDesign` |
The resampling design |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.