Function to extract attributes from objects.
extract_attribute
expects the input object to be the target. When
the target object is nested in a list (as is the case in
datasetsXLSX
), extract_attributes
should be used instead.
extract_attribute(object, which, required_val = FALSE)
extract_attributes(object_list, which, required_val = FALSE)
Object to extract attribute from. In practice a data.frame, ggplot object, or a character string providing a path to an image.
Name of the attribute to extract.
Boolean, if TRUE tries to look up a default in global options if attribute not found, and raises an error if none was defined.
A list of objects of arbitrary types.