Displaying 4 results from an estimated 4 matches for "sorted_decr".
2019 Sep 03
2
[ALTREP] What is the meaning of the return value of Is_sorted and No_NA function?
Hi,
I would like to figure out the meaning of the return value of these two
functions. Here are the default definitions I find from R source code:
static int altreal_Is_sorted_default(SEXP x) { return UNKNOWN_SORTEDNESS; }
static int altreal_No_NA_default(SEXP x) { return 0; }
I guess the macro *UNKNOWN_SORTEDNESS *in *Is_sorted* and 0 in *No_NA
*simply means
unknown sorted/NA status of
2019 Sep 04
0
[ALTREP] What is the meaning of the return value of Is_sorted and No_NA function?
Hi,
I've found the answers to my questions:
1. For sort function, here are some macros defined in Rinternal.h:
/* ALTREP sorting support */
enum {SORTED_DECR_NA_1ST = -2,
SORTED_DECR = -1,
UNKNOWN_SORTEDNESS = INT_MIN, /*INT_MIN is NA_INTEGER! */
SORTED_INCR = 1,
SORTED_INCR_NA_1ST = 2,
KNOWN_UNSORTED = 0};
The macro names are pretty self-explanatory. The current implementation
only supports the ascending sort.
2. For any...
2019 Sep 11
0
[ALTREP] What is the meaning of the return value of Is_sorted and No_NA function?
Hi Jiefei,
The meanings of the return values for sortedness can be found in
RInternals.h, and are as follows:
/* ALTREP sorting support */
enum {SORTED_DECR_NA_1ST = -2,
SORTED_DECR = -1,
UNKNOWN_SORTEDNESS = INT_MIN, /*INT_MIN is NA_INTEGER! */
SORTED_INCR = 1,
SORTED_INCR_NA_1ST = 2,
KNOWN_UNSORTED = 0};
The default value there is NA_INTEGER (ie INT_MIN), indicating that there
is no sortedness information.
Currently, *...
2019 Sep 11
1
[ALTREP] What is the meaning of the return value of Is_sorted and No_NA function?
...e by doing that.
Best,
Jiefei
On Wed, Sep 11, 2019 at 1:58 PM Gabriel Becker <gabembecker at gmail.com>
wrote:
> Hi Jiefei,
>
> The meanings of the return values for sortedness can be found in
> RInternals.h, and are as follows:
>
> /* ALTREP sorting support */
> enum {SORTED_DECR_NA_1ST = -2,
> SORTED_DECR = -1,
> UNKNOWN_SORTEDNESS = INT_MIN, /*INT_MIN is NA_INTEGER! */
> SORTED_INCR = 1,
> SORTED_INCR_NA_1ST = 2,
> KNOWN_UNSORTED = 0};
>
> The default value there is NA_INTEGER (ie INT_MIN), indicating that there
> is n...