capwords: capwords

Description Usage Arguments Value Note Author(s) Examples

View source: R/capwords.r

Description

This function capitalizes words

Usage

1
capwords(s, strict = FALSE, sentence = T)

Arguments

s

= the string to handle

strict

= if TRUE, forces capitalization of all words (as long as sentence = F)

sentence

= if TRUE, only the first word is capitalized

Value

character vector

Note

taken from help of 'toupper'

Author(s)

unknown, <unknown>@dfo-mpo.gc.ca

Examples

1
2
3
4
5
6
7
8
capwords('this is a test', F, T)
[1] "This is a test"
capwords('this is a test', T, T)
[1] "This is a test"
capwords('this is a test', T, F)
[1] "This Is A Test"
capwords('this is a test', F, F)
[1] "This Is A Test"

Beothuk/bio.utilities documentation built on May 5, 2019, 1:39 p.m.