R_xlen_t | R Documentation |
Type Definition: 'R_xlen_t' and 'R_len_t'
#include <Rinternals.h>
R_xlen_t
R_len_t
An object of class typedef
of length 1.
Long vectors:
typedef ptrdiff_t R_xlen_t; define R_XLEN_T_MAX 4503599627370496
Short vectors:
typedef int R_len_t; #define R_LEN_T_MAX INT_MAX
If long vectors are not supported on the current platform, then:
LONG_VECTOR_SUPPORT
is not defined and we have:
typedef int R_xlen_t; define R_XLEN_T_MAX R_LEN_T_MAX
library(base) # Maximum length of a "short" vector ... x <- seq_len(.Machine$integer.max) xlen <- length(x) # integer; internally R_len_t # ... before becoming a "long" vector x <- seq_len(.Machine$integer.max + 1) xlen <- length(x) # numeric; internally R_xlen_t
Declaration: src/include/Rinternals.h
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.