kwb.utils
General Utility Functions Developed at KWB
The utility layer under KWB's R packages, growing by accretion one helper at a time.
◆Recent moves
- 1y ago
loadFunctions() and callWithData() extend the toolbox to code
loadFunctions(), callWithData() and mergeEnvironments() push the package past data manipulation into loading and invoking code with supplied environments. multiColumnLookup() gains multiple value columns with drop and includeKeys arguments, and findPartialDuplicates() is reimplemented to fix a bug — the usual mix of new surface plus targeted repair.
View source ↗ - 3y ago
Twelve new helpers for paths, warnings and extdata files
The largest single batch of additions in this window: assignObjects(), catchWarning(), extdataFile(), directoryName(), stopFormatted() and more, with hsAddMissingCols() and extractSubstring() reimplemented. subexpressionMatches() renames its regularExpression argument to pattern, continuing the package's habit of tidying argument names as it goes.
View source ↗ - 4y ago
clipMatrix() added; extractRowRanges() reworked for vectors
New arguments spread across substSpecialChars(), inRange() and makeUnique(), plus a new clipMatrix(). extractRowRanges() is reworked to accept character vectors and its arguments renamed and reordered — a signature change callers have to follow, of the kind this package makes without ceremony.
View source ↗ - 5y ago
Caching internals and encoding-aware line reading arrive
Private cache-directory functions land alongside readLinesWithEncoding(), moved in from fakin.path.app — a clear instance of the consolidation role this package plays. orderBy() gains multi-column ordering and readDictionary() picks up file encoding arguments.
View source ↗ - 6y ago
Fourteen new functions; assignGlobally() deprecated
A wide release adding accessors, storage, sampling and text-conversion helpers, with the first serious pruning of the old API: assignGlobally() deprecated and hsSubstSpecChars() renamed to substSpecialChars(). The reproducible-sample function even brings its own S3 print method.
View source ↗ - 6y ago
listToDepth() and six small string helpers
A short release adding a generic list function and a handful of one-line string helpers such as left(), right() and space(). Several of these are revisited in the next version, which is how this package tends to settle a new function's shape.
View source ↗