ud.set.encoding | R Documentation |
This function sets the encoding type parameter which is global to the R udunits2 package.
ud.set.encoding(enc.string)
enc.string |
A character string representing the encoding type.
Valid strings are |
Encoding type is a parameter to nearly all of the functions in the udunits library. By default, the R udunits2 pacakge sets the encoding type to UTF-8, however this package allows the user to set other encoding types which are supported by the udunits library. It presently suports UTF-8, ASCII, and ISO-8859-1
Returns no value. Raises an error if it is not given a valid encoding string.
James Hiebert hiebert@uvic.ca
Unidata's udunits reference: https://www.unidata.ucar.edu/software/udunits/ API guide chapter on data types: https://www.unidata.ucar.edu/software/udunits/udunits-2.1.24/udunits2lib.html#Types
valid.enc.strings <- c('utf8', 'ascii', 'iso-8859-1', 'latin1') lapply(valid.enc.strings, ud.set.encoding) err <- try(ud.set.encoding("This will fail"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.