Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

listOf

Tests equality of list elements class


Description

Compares equality of all members of a list.

Usage

listOf(x, class, valid = TRUE)

Arguments

x

A codelist.

class

A character defining the expected class.

valid

A logical defining if all elements should be tested for validity. Default is TRUE.

Value

TRUE is all elements of x inherit from class.

Author(s)

Laurent Gatto

Examples

listOf(list(), "foo")
listOf(list("a", "b"), "character")
listOf(list("a", 1), "character")

MSnbase

Base Functions and Classes for Mass Spectrometry and Proteomics

v2.16.1
Artistic-2.0
Authors
Laurent Gatto, Johannes Rainer and Sebastian Gibb with contributions from Guangchuang Yu, Samuel Wieczorek, Vasile-Cosmin Lazar, Vladislav Petyuk, Thomas Naake, Richie Cotton, Arne Smits, Martina Fisher, Ludger Goeminne, Adriaan Sticker and Lieven Clement.
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.