Description Usage Arguments Details Value Note Author(s) See Also Examples
Function vmode
returns virtual storage modes of 'ram' or 'ff' objects, the generic vmode<-
sets the vmode of ram objects (vmode of ff objects cannot be changed).
1 2 3 4 5 6 7 8 9 10 11 |
x |
any object |
value |
a vmode from .vmode |
... |
The |
vmode
is generic with default and ff methods. The following meta data vectors can be queried by .vmode or .ffmode:
.vmode | virtual mode |
.vunsigned | TRUE if unsigned vmode |
.vvalues | number of possible values (incl. NA) |
.vimplemented | TRUE if this vmode is available in ff (initialized .onLoad and stored in globalenv ) |
.rammode | storage mode of this vmode |
.ffmode | integer used to code the vmode in C-code |
.vvalues | number of possible integers incl. NA in this vmode (or NA for other vmodes) |
.vmin | min integer in this vmode (or NA for other vmodes) |
.vmax | max integer in this vmode (or NA for other vmodes) |
.vNA | NA or 0 if no NA for this vmode |
.rambytes | bytes needed in ram |
.ffbytes | bytes needed by ff on disk |
.vcoerceable | list of vectors with those vmodes that can absorb this vmode |
the following functions relate to vmode:
vector.vmode | creating (ram) vector of some vmode |
as.vmode | generic for coercing to some vmode (dropping other attributes) |
vmode<- | generic for coercing to some vmode (keeping other attributes) |
maxffmode | determine lowest .ffmode that can absorb all input vmodes without information loss |
some of those call the vmode-specific functions:
creation | coercion | vmode description |
boolean | as.boolean | 1 bit logical without NA |
logical | as.logical | 2 bit logical with NA |
quad | as.quad | 2 bit unsigned integer without NA |
nibble | as.nibble | 4 bit unsigned integer without NA |
byte | as.byte | 8 bit signed integer with NA |
ubyte | as.ubyte | 8 bit unsigned integer without NA |
short | as.short | 16 bit signed integer with NA |
ushort | as.ushort | 16 bit unsigned integer without NA |
integer | as.integer | 32 bit signed integer with NA |
single | as.single | 32 bit float |
double | as.double | 64 bit float |
complex | as.complex | 2x64 bit float |
raw | as.raw | 8 bit unsigned char |
character | as.character | character |
vmode
returns a character scalar from .vmode
or "NULL" for NULL
rambytes
returns a vector of byte counts required by each of the vmodes
regtest.vmode
checks correctness of some vmode features
Jens Oehlschl<c3><a4>gel
1 2 3 4 5 6 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.