1
function calculate () {
2
var object = getValue ("object");
3
var is_data_frame = (getValue ("sortby_frame.enabled") == "true");
6
if (getValue ("saveto_select") == "other") saveto = getValue ("saveto");
7
var sortby = getValue ("sortby");
8
if (!is_data_frame) sortby = object;
10
echo (".GlobalEnv$" + saveto + " <- " + object + "[order (" + sortby + getValue ("order") + ")");
11
if (is_data_frame) echo (",");