search for: r_dropsymbol

Displaying 2 results from an estimated 2 matches for "r_dropsymbol".

2006 Sep 08
1
R drop behavior -- set as option in later version?
...ing code: ------------ /* Extracts the drop argument, if present, from the argument list. The object being subsetted must be the first argument. */ static void ExtractDropArg(SEXP el, int *drop) { SEXP last = el; for (el = CDR(el); el != R_NilValue; el = CDR(el)) { if(TAG(el) == R_DropSymbol) { *drop = asLogical(CAR(el)); if (*drop == NA_LOGICAL) *drop = 1; SETCDR(last, CDR(el)); } else last = el; } } ------------ This is not exactly the right syntax for a GetOption call, but something along the following lines should allow globa...
2006 Sep 08
1
R drop behavior -- set as option in later version?
...ing code: ------------ /* Extracts the drop argument, if present, from the argument list. The object being subsetted must be the first argument. */ static void ExtractDropArg(SEXP el, int *drop) { SEXP last = el; for (el = CDR(el); el != R_NilValue; el = CDR(el)) { if(TAG(el) == R_DropSymbol) { *drop = asLogical(CAR(el)); if (*drop == NA_LOGICAL) *drop = 1; SETCDR(last, CDR(el)); } else last = el; } } ------------ This is not exactly the right syntax for a GetOption call, but something along the following lines should allow globa...