paste_oxford_list {schtools} | R Documentation |
Create a prose string from a list or vector
Description
The word 'and' is inserted before the last element and an Oxford comma is used.
Usage
paste_oxford_list(x)
Arguments
x |
a list or vector |
Value
a string where each element in x
is separated by a comma
Author(s)
Pat Schloss pschloss@umich.edu
Kelly Sovacool sovacool@umich.edu
Examples
paste_oxford_list(1:3)
paste_oxford_list(c("cats", "dogs", "turtles"))
[Package schtools version 0.4.1 Index]