Description Usage Arguments Details Value Examples
Generic function to trim leading and trailing blanks from character vectors and factors.
1 | trim(x)
|
x |
a data frame, factor, character or numeric vector |
The main application is in reading SPSS files that often have leading or trailing blanks in
character and factor values. These blanks are often inconsistent so that values will
appear to differ even though they are equal. The trim function is called in Read.spss
to
remove leading and trailing blanks from all factors.
A character vector or factor with leading and trailing blanks removed.
1 2 3 4 5 6 7 8 9 10 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.