5
function calculate () {
6
p = "c (" + preg_replace ("/[, ]+/", ", ", getValue ("p")) + ")";
8
echo ('result <- (qchisq (p = ' + p + ', df = ' + getValue ("df") + ', ncp = ' + getValue ("ncp") + ', ' + getValue ("tail") + ', ' + getValue ("logp") + '))\n');
11
function printout () {
12
echo ('rk.header ("Chi-squared quantile", list ("Vector of probabilities", "' + p + '", "Degrees of freedom", "' + getValue ("df") + '", "non-centrality parameter", "' + getValue ("ncp") + '", "Tail", "' + getValue ("tail") + '", "Probabilities p are given as", "' + getValue ("logp") + '"));\n');
13
echo ('rk.results (result, titles="Chi-squared quantiles")\n');