| 1 | 
| x | |
| y | |
| alpha | |
| bend | |
| nboot | |
| SEED | 
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | ##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.
## The function is currently defined as
function (x, y, alpha = 0.05, bend = 1.28, nboot = 599, SEED = TRUE) 
{
    if (SEED) 
        set.seed(2)
    T <- bsqrm(x, y, alpha, bend)$teststat
    TT <- 0
    bsqrmbt <- numeric(2)
    xone <- onestep(x, bend = bend)
    yone <- onestep(y, bend = bend)
    for (j in 1:nboot) {
        xx <- (sample(x, length(x), replace = TRUE) - xone)
        yy <- (sample(y, length(y), replace = TRUE) - yone)
        TT[j] <- bsqrm(xx, yy, alpha, bend)$teststat
    }
    TT <- sort(TT)
    bott <- round(alpha * nboot) + 1
    bsqrmbt <- TT[nboot - bott]
    pv = mean(T <= TT)
    list(critval = bsqrmbt, teststat = TRUE, p.value = pv)
  }
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.