Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

sortStanza

Move missing values to last row in long key block


Description

Receive key stanza and sort the rows so that the missing values are last in the list. Leaves ordering of other rows unchanged otherwise.

Usage

sortStanza(keyblock, valvar = "value_new", na.strings = c("\\.", "",
  "\\s+", "N/A"))

Arguments

keyblock

a variable key, or section of rows

valvar

Default is "value_new", the column for sorting.

na.strings

Stings to be treated as missing, along with R's NA symbol

Value

keyblock, row re-arranged with missings last


kutils

Project Management Tools

v1.70
GPL-2
Authors
Paul Johnson [aut, cre], Benjamin Kite [aut], Charles Redmon [aut], Jared Harpole [ctb], Kenna Whitley [ctb], Po-Yi Chen [ctb], Shadi Pirhosseinloo [ctb]
Initial release
2020-04-28

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.