Package: hutils 1.8.2

hutils: Miscellaneous R Functions and Aliases

Provides utility functions for, and drawing on, the 'data.table' package. The package also collates useful miscellaneous functions extending base R not available elsewhere. The name is a portmanteau of 'utils' and the author.

Authors:Hugh Parsonage [aut, cre], Michael Frasco [ctb], Ben Hamner [ctb]

hutils_1.8.2.tar.gz
hutils_1.8.2.zip(r-4.5)hutils_1.8.2.zip(r-4.4)hutils_1.8.2.zip(r-4.3)
hutils_1.8.2.tgz(r-4.4-any)hutils_1.8.2.tgz(r-4.3-any)
hutils_1.8.2.tar.gz(r-4.5-noble)hutils_1.8.2.tar.gz(r-4.4-noble)
hutils_1.8.2.tgz(r-4.4-emscripten)hutils_1.8.2.tgz(r-4.3-emscripten)
hutils.pdf |hutils.html
hutils/json (API)
NEWS

# Install 'hutils' in R:
install.packages('hutils', repos = c('https://hughparsonage.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/hughparsonage/hutils/issues

On CRAN:

7.87 score 12 stars 8 packages 209 scripts 2.5k downloads 74 exports 3 dependencies

Last updated 2 years agofrom:11e6f82887. Checks:OK: 7. Indexed: yes.

TargetResultDate
Doc / VignettesOKNov 01 2024
R-4.5-winOKNov 01 2024
R-4.5-linuxOKNov 01 2024
R-4.4-winOKNov 01 2024
R-4.4-macOKNov 01 2024
R-4.3-winOKNov 01 2024
R-4.3-macOKNov 01 2024

Exports:%<->%%ein%%enotin%%implies%%notchin%%notin%%pin%ahullall_same_signANDany_greplaucaverage_bearingaverage_bearing_nbearingcoalescecompass2bearingdev_copy2a4dir2drop_coldrop_colrdrop_colsdrop_constant_colsdrop_empty_colsdrop_grepduplicated_rowseasterly_componentfind_pattern_infst_columnsfst_nrowgenerate_LaTeX_manualgoto_pattern_inhas_unique_keyhaversine_distanceif_elseimpliesisAttachedlongest_prefixlongest_suffixmean_naModemutate_ntilemutate_otherneitherNEITHERngrepnorNORnortherly_componentORpowprohibit_unequal_length_vectorsprohibit_vector_recyclingprohibit_vector_recycling.MAXLENGTHprovide.dirprovide.filereplace_pattern_inreport_errorRQsampselect_grepselect_whichselectorseq_nrowset_cols_firstset_cols_lastset_colsuborderset_unique_keySwitchtrim_common_affixesweight2rowsweighted_ntileweighted_quantileXOR

Dependencies:data.tablefastmatchmagrittr

Hutils

Rendered fromhutils.Rmdusingknitr::rmarkdownon Nov 01 2024.

Last update: 2021-06-01
Started: 2017-09-16

Readme and manuals

Help Manual

Help pageTopics
hutils packagehutils-package
Exists and (not) in%ein% %enotin%
Negation of in (character)%notchin%
Negation of in%notin%
Partial in%pin%
Maximum area given x and y coordinatesahull
Aliasesaliases AND NEITHER neither NOR nor OR pow XOR
Determine whether a vector is all of the same signall_same_sign
Does the pattern appear anywhere?any_grepl
AUCauc
Average of bearingsaverage_bearing average_bearing_n
Bearing calculationsbearing compass2bearing easterly_component northerly_component
Find first non-missing elementcoalesce
Copy device to an A4 PDFdev_copy2a4
List many filesdir2
Drop column or columnsdrop_col drop_cols
Drop columns whose names match a patterndrop_colr drop_grep
Drop constant columnsdrop_constant_cols
Drop empty columnsdrop_empty_cols
Return duplicated rows of data.tableduplicated_rows
Find string pattern in (text) filefind_pattern_in goto_pattern_in
Utilities for `fst` filesfst_columns fst_nrow
Generate LaTeX manual of installed packagegenerate_LaTeX_manual
Distance between two points on the Earthhaversine_distance
Vectorized ifif_else
#' Logical implies%implies% implies
Is a package attached?isAttached
Logical assertionsisTrueFalse
Longest common prefix/suffixlongest_affix longest_prefix longest_suffix trim_common_affixes
Proportion of values that are NA.mean_na
Statistical modeMode
Add a column of ntiles to a data tablemutate_ntile
Group infrequent entries into 'Other category'mutate_other
Anti-grepngrep
Prohibit unequal length vectorsprohibit_unequal_length_vectors
Prohibit vector recyclingprohibit_vector_recycling prohibit_vector_recycling.MAXLENGTH
Provide directoryprovide.dir
Provide a fileprovide.file
Replace string pattern in text filereplace_pattern_in
Report errors and warningsreport_error
Shorthand for 'requireNamespace'RQ
Safer samplersamp
Select names matching a patternselect_grep
Select columns satisfying a conditionselect_which
Fast selection of 'data.table' columnsselector
Generate sequence of row numbersseq_nrow
Put columns first or lastset_colsuborder set_cols_first set_cols_last
Swap assignment%<->% swap
Vectorized switchSwitch
Unique keyshas_unique_key set_unique_key unique-keys
Expand a weighted data frame to an equivalent unweightedweight2rows
Weighted (ranked) quantilesweighted_ntile
Weighted quantileweighted_quantile