WFS_util_check_in_list | R Documentation |
With the default parameters the function is checking without caring for lower and upper caps
if a list has an entry with a certain name and value. When a name occurs more than once
the first (if keep.first==TRUE
) or last (otherwise) occurrence is examined.
By specifying the ignore_case
arguments to FALSE
the user
can indicate that the difference in lower and upper caps is important when comparing 'names'
(in case of name_ignore_case
) and/or 'values' (in case of value_ignore_case
).
WFS_util_check_in_list( mylist, name, value, keep_first = T, name_ignore_case = T, value_ignore_case = T )
mylist |
A named list with character contents |
name |
Character string with the name of the entry that is searched |
value |
A character scalar to check for in the |
name_ignore_case |
Logical scalar indicating if case is ignored when searching for the name |
value_ignore_case |
Logical scalar indicating if case is ignored when checking the value |
keep.first |
Logical scalar indicating if the first (when |
Logical value indicating if the name
entry contains the value value
WFS_util_check_in_list( mylist = list(a='x',b='y',b='Y'), name = 'B', value = 'Y', value_ignore_case = F ) # [1] FALSE # first entry B found with value y (unequal to Y)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.