R.utils v2.9.2

0

Monthly downloads

0th

Percentile

Various Programming Utilities

Utility functions useful when programming and developing R packages.

Functions in R.utils

Name Description
Non-documented objects Non-documented objects
TimeoutException TimeoutException represents timeout errors
Settings Class for applicational settings
Assert The Assert class
Arguments Static class to validate and process arguments
SmartComments Abstract class SmartComments
addFinalizerToLast Modifies .Last() to call 'finalizeSession()
capitalize Capitalizes/decapitalizes each character string in a vector
as.character.GString Gets the processed character string
callHooks.function Call hook functions
System$currentTimeMillis Get the current time in milliseconds
as.character.Options Returns a character string version of this object
cleanup.FileProgressBar Removes the progress file for a file progress bar
cmdArgs Simple access to parsed command-line arguments
dataFrame Allocates a data frame with given column classes
downloadFile.character Downloads a file
file.info2 Extract File Information (acknowledging symbolic file links also on Windows)
draw.density Draws a density curve
fileAccess Checks the permission of a file or a directory
findSourceTraceback Finds all 'srcfile' objects generated by source() in all call frames
flush.TextStatusBar Flushes the output
GString$getBuiltinPid Gets the process id of the current R session
VComments The VComments class
NullVerbose A Verbose class ignoring everything
Options The Options class
as.character.ProgressBar Gets a string description of the progress bar
System$getHostname Retrieves the computer name of the current host
Arguments$getFilename Gets and validates a filename
GString$getBuiltinRhome Gets the path where R is installed
Java$asLong Converts a numeric to a Java long
compile.SmartComments Preprocess a vector of code lines
Java$asShort Converts a numeric to a Java short
commandArgs Extract command-line arguments
Verbose Class to writing verbose messages to a connection or file
convertComment.SmartComments Converts a single smart comment to R code
as.double.Verbose Gets a numeric value of this object
as.list.MultiVerbose Gets a list of Verbose objects
attachLocally.list Assigns an objects elements locally
convertComment.VComments Converts a verbose comment to R code
eget Gets a variable by name
FileProgressBar A progress bar that sets the size of a file accordingly
Java Static class for Java related methods
egsub Global substitute of expression using regular expressions
GString Character string with advanced substitutions
R.utils-package Package R.utils
as.logical.Verbose Gets a logical value of this object
cmdArgsCall Calls an R function passing command-line arguments
callHooks Call hook functions by hook name
as.list.Options Gets a list representation of the options
ProgressBar Provides text based counting progress bar
colClasses Creates a vector of column classes used for tabular reading
Java$asByte Converts a numeric to a Java byte
as.character.Verbose Returns a character string version of this object
capture.Verbose Captures output of a function
Sys.readlink2 Read File Symbolic Links (also on Windows)
System Static class to query information about the system
LComments The LComments class
as.character.binmode Converts a binary/octal/hexadecimal number into a string
captureOutput Evaluate an R expression and captures the output
cat.Verbose Concatenates and prints objects if above threshold
countLines Counts the number of lines in a text file
Assert$check Static method asserting that a generic condition is true
createFileAtomically Creates a file atomically
gstring Parses and evaluates a GString into a regular string
getRaw.GString Gets the unprocessed GString
hpaste Concatenating vectors into human-readable strings
isFile Checks if the file specification is a file
header.Verbose Writes a header
Arguments$getWritablePathname Gets a writable pathname
getParent Gets the string of the parent specified by this pathname
Assert$isMatrix Static method asserting that an object is a matrix
Java$asInt Converts an numeric to a Java integer
isPackageInstalled Checks if a package is installed or not
detachPackage Detaches packages by name
isPackageLoaded Checks if a package is loaded or not
gcat Parses, evaluates and outputs a GString
evaluate.GString Parses and evaluates a GString
gcDLLs Identifies and removes DLLs of packages already unloaded
evaluate.Verbose Evaluates a function and prints its results if above threshold
dimNA< - Sets the dimension of an object with the option to infer one dimension automatically
equals.Options Checks if this object is equal to another Options object
findFiles Finds one or several files in multiple directories
equals.Verbose Checks if this object is equal to another
System$findGhostscript Searches for a Ghostview executable on the current system
copyDirectory Copies a directory
compressFile Compressing and decompressing files
compressPDF Compresses a PDF (into a new PDF)
createLink Creates a link to a file or a directory
GString$getBuiltinUsername Gets the username of the user running R
GString$getBuiltinHostname Gets the hostname of the system running R
copyFile Copies a file atomically
GString$getBuiltinOs Gets the operating system of the running machine
Arguments$getIndices Coerces to a integer vector and validates
displayCode Displays the contents of a text file with line numbers and more
doCall Executes a function call with option to ignore unused arguments
createWindowsShortcut Creates a Microsoft Windows Shortcut (.lnk file)
Arguments$getInstanceOf Gets an instance of the object that is of a particular class
enter.Verbose Writes a message and indents the following output
on.Verbose Turn on the output
mergeIntervals.numeric Merges intervals
mapToIntervals.numeric Maps values to intervals
off.Verbose Turn off the output
Arguments$getCharacters Coerces to a character vector and validates
Arguments$getIntegers Coerces to a integer vector and validates
exit.Verbose Writes a message and unindents the following output
env Creates a new environment, evaluates an expression therein, and returns the environment
filePath Construct the path to a file from components and expands Windows Shortcuts along the pathname from root to leaf
popMessage.TextStatusBar Adds a message above the status bar
getAbsolutePath Gets the absolute pathname string
Arguments$getLogicals Coerces to a logical vector and validates
extract.array Extract a subset of an array, matrix or a vector with unknown dimensions
getBarString.ProgressBar Gets the progress bar string to be displayed
popTemporaryFile Drops a temporary suffix from the temporary pathname
GString$getBuiltinDate Gets the current date
getMessage.TimeoutException Gets the message of the exception
Arguments$getNumerics Coerces to a numeric vector and validates
getLabel.TextStatusBar Gets the current value of a label
System$getUsername Retrieves the name of the user running R
GString$getBuiltinDatetime Gets the current date and time
hasOption.Options Checks if an option exists
getOption.Options Gets an option
inAnyInterval.numeric Checks if a set of values are inside one or more intervals
GString$getVariableValue Gets a variable value given a name and attributes
hsize Convert byte sizes into human-readable byte sizes
System$findGraphicsDevice Searches for a working PNG device
finalizeSession Function to call for finalizing the R session
GString$getBuiltinRversion Gets the current R version
Arguments$getRegularExpression Gets a valid regular expression pattern
GString$getBuiltinTime Gets the current time
Arguments$getEnvironment Gets an existing environment
Arguments$getDoubles Coerces to a double vector and validates
Settings$findSettings Searches for the settings file in one or several directories
getRelativePath Gets the relative pathname relative to a directory
pushState.Verbose Pushes the current indentation state of the Verbose object
withLocale Evaluate an R expression with locale set temporarily
pushTemporaryFile Appends a temporary suffix to the pathname
getLoadedPathname.Settings Gets the pathname of the settings file loaded
getLeaves.Options Gets all (non-list) options in a flat list
intToBin Converts an integer to a binary/octal/hexadecimal number
Arguments$getVerbose Coerces to Verbose object
Arguments$getReadablePathname Gets a readable pathname
Arguments$getVector Validates a vector
increase.ProgressBar Increases (steps) progress bar
Assert$inheritsFrom Static method asserting that an object inherits from of a certain class
hasUrlProtocol Checks if one or several pathnames has a URL protocol
isAbsolutePath Checks if this pathname is absolute
Arguments$getReadablePathnames Gets a readable pathname
isDirectory Checks if the file specification is a directory
getThreshold.Verbose Gets current verbose threshold
isModified.Settings Checks if settings has been modified compared to whats on file
isOn.NullVerbose Checks if the output is on
intervalsToSeq.matrix Generates a vector of indices from a matrix of intervals
getTimestampFormat.Verbose Gets the default timestamp format
isSingle Identifies all entries that exists exactly once
readWindowsShellLink Reads a Microsoft Windows Shortcut (.lnk file)
insert Insert values to a vector at certain positions
installPackages Install R packages by name or URL
isUrl Checks if one or several pathnames is URLs
isOn.Verbose Checks if the output is on
more.Verbose Creates a cloned instance with a lower threshold
mkdirs Creates a directory including any necessary but nonexistent parent directories
isZero Checks if a value is (close to) zero or not
isOpen.character Checks if there is an open connection to a file
loadObject Method to load object from a file or a connection
isVisible.Verbose Checks if a certain verbose level will be shown or not
withCapture Evaluates an expression and captures the code and/or the output
Java$readUTF Reads a Java (UTF-8) formatted string from a connection
loadToEnv Method to load objects to a new environment
Assert$isVector Static method asserting that an object is a vector
ruler.Verbose Writes a ruler
saveAnywhere.Settings Saves settings to file
setLabels.TextStatusBar Sets new values of given labels
newline.Verbose Writes one or several empty lines
Java$writeUTF Writes a string to a connection in Java format (UTF-8)
sourceTo Parses and evaluates code from a file or a connection
setLabel.TextStatusBar Sets the value of a label
sourceDirectory Sources files recursively to either local or global environment
nullfile Gets the pathname or a connection to the NULL device on the current platform
lastModified Gets the time when the file was last modified
less.Verbose Creates a cloned instance with a higher threshold
isVisible.NullVerbose Checks if a certain verbose level will be shown or not
isDone.ProgressBar Checks if progress bar is completed
System$parseDebian Parses a string, file or connection for Debian formatted parameters
isEof.connection Checks if the current file position for a connection is at the 'End of File'
parse.SmartComments Parses one single smart comment
update.FileProgressBar Updates file progress bar
toCamelCase Converts a string of words into a merged camel-cased word
nbrOfOptions.Options Gets the number of options set
isReplicated Identifies all entries with replicated values
newline.TextStatusBar Writes a newline
parse.GString Parses a GString
System$openBrowser Opens an HTML document using the OS default HTML browser
readTableIndex Reads a single column from file in table format
Assert$isScalar Static method asserting that an object is a single value
moveInSearchPath Moves a environment in the search path to another position
mout Miscellaneous functions for outputting via message()
onGarbageCollect Registers a function to be called when the R garbage collector is (detected to be) running
onSessionExit Registers a function to be called when the R session finishes
toUrl Converts a pathname into a URL
update.ProgressBar Updates progress bar
listDirectory Gets the file names in the directory
print.GString Prints the processed GString
print.Verbose Prints objects if above threshold
setDefaultLevel.Verbose Sets the current default verbose level
reassignInPackage Re-assigns a new value to an existing object in a loaded package
renameFile Renames a file (or a directory) atomically/safely
readWindowsShortcut Reads a Microsoft Windows Shortcut (.lnk file)
shell.exec2 Open a file or URL using Windows File Associations
loadAnywhere.Settings Loads settings from file
queryRCmdCheck Gets the on R CMD check if the current R session was launched by it
readBinFragments Reads binary data from disjoint sections of a connection or a file
reset.SmartComments Resets a SmartComments compiler
setValue.ProgressBar Sets current value
swapXY.density Swaps x and y coordinates of a density object
readRdHelp Reads one or more Rd help files in a certain format
reset.VComments Resets a VComments compiler
Java$readShort Reads a Java formatted short (16 bits) from a connection
readTable Reads a file in table format
str.Verbose Prints the structure of an object if above threshold
mpager A \"pager\" function that outputs to standard error
saveObject Saves an object to a file or a connection
setMaxValue.ProgressBar Sets maximum value
pushBackupFile Appends a backup suffix to the pathname
promptAndSave.Settings Prompt user to save modified settings
use Attaches or loads packages
setOption Sets a option in R
popBackupFile Drops a backup suffix from the backup pathname
patchCode Patches installed and loaded packages and more
names.Options Gets the full pathname of all (non-list) options
seqToHumanReadable Gets a short human readable string representation of an vector of indices
removeDirectory Removes a directory
validate.VComments Validates the compiled lines
validate.SmartComments Validates the compiled lines
seqToIntervals Gets all contiguous intervals of a vector of indices
str.Options Prints the structure of the options
summary.Verbose Generates a summary of an object if above threshold
withSeed Evaluate an R expression with a temporarily set random set
setOption.Options Sets an option
Java$writeByte Writes a byte (8 bits) to a connection in Java format
timestampOn.Verbose Turns automatic timestamping on and off
setProgress.ProgressBar Sets current progress
writeRaw.Verbose Writes objects if above threshold
unwrap.array Unwrap an array, matrix or a vector to an array of more dimensions
splitByPattern Splits a single character string by pattern
warnings.Verbose Outputs any warnings recorded
stext Writes text in the margin along the sides of a plot
useRepos Sets package repositories
printf.Verbose Formats and prints object if above threshold
withOptions Evaluate an R expression with options set temporarily
systemR Launches another R process from within R
touchFile Updates the timestamp of a file
withRepos Evaluate an R expression with repositories set temporarily
tmpfile Creates a temporary file with content
withSink Evaluate an R expression while temporarily diverting output
writeBinFragments Writes binary data to disjoint sections of a connection or a file
subplots Creates a grid of subplots
Java$writeShort Writes a short (16 bits) to a connection in Java format
writeDataFrame.data.frame Writes a data.frame to tabular text file
Java$writeInt Writes a integer (32 bits) to a connection in Java format
whichVector.logical Identifies TRUE elements in a logical vector
setStepLength.ProgressBar Sets default step length
Java$readInt Reads a Java formatted int (32 bits) from a connection
printf C-style formatted output
tempvar Gets a unique non-existing temporary variable name
Java$readByte Reads a Java formatted byte (8 bits) from a connection
setThreshold.Verbose Sets verbose threshold
updateLabels.TextStatusBar Sets the new values of given labels and updates the status bar
reset.ProgressBar Reset progress bar
resample Sample values from a set of elements
setTimestampFormat.Verbose Sets the default timestamp format
writeRaw.MultiVerbose Writes to each of the Verbose objects
timestamp.Verbose Writes a timestamp
withTimeout Evaluate an R expression and interrupts it if it takes too long
writeRaw.NullVerbose All output methods
setTicks.ProgressBar Sets values for which ticks should be visible
wrap.array Reshape an array or a matrix by permuting and/or joining dimensions
update.TextStatusBar Updates the status bar (visually)
MultiVerbose A Verbose class ignoring everything
TextStatusBar A status bar at the R prompt that can be updated
No Results!

Last month downloads

Details

License LGPL (>= 2.1)
LazyLoad TRUE
URL https://github.com/HenrikBengtsson/R.utils
BugReports https://github.com/HenrikBengtsson/R.utils/issues
NeedsCompilation no
Packaged 2019-12-07 19:30:11 UTC; hb
Repository CRAN
Date/Publication 2019-12-08 07:50:02 UTC

Include our badge in your README

[![Rdoc](http://www.rdocumentation.org/badges/version/R.utils)](http://www.rdocumentation.org/packages/R.utils)