sclass | R Documentation |
return the classes of a list of objects
sclass(x, ...)
x |
an S3 object inheriting from class |
... |
additional parameters are ignored. |
This function takes a list
and returns the classes for each
object in the list. In the event an object class has multiple values,
the returned object is a list, otherwise is a vector.
If x
is an S4 object, then slotNames(x)
is used, and
the class is returned for each S4 slot.
When x
is a data.frame
, data.table
, tibble
, or similar
DataFrame
table-like object, the class of each column is returned.
For the special case where x
is an S4 object with one slotName
".Data"
, the values in x@.Data
are coerced to a list
. One
example of this case is with limma::MArrayLM-class
.
When x
is a matrix, the class of each column is returned for
consistency, even though the class of each column should be identical.
For more more information about a list-like object, including
the lengths/dimensions of the elements, see sdim()
or ssdim()
.
character
vector with the class of each list element, or
column name, depending upon the input class(x)
.
Other jam practical functions:
breakDensity()
,
checkLightMode()
,
check_pkg_installed()
,
colNum2excelName()
,
color_dither()
,
diff_functions()
,
exp2signed()
,
fileInfo()
,
fixYellow()
,
getAxisLabel()
,
handleArgsText()
,
heads()
,
isFALSEV()
,
isTRUEV()
,
jamba
,
jargs()
,
kable_coloring()
,
lldf()
,
log2signed()
,
make_html_styles()
,
make_styles()
,
match_unique()
,
mergeAllXY()
,
middle()
,
minorLogTicks()
,
newestFile()
,
printDebug()
,
renameColumn()
,
rmInfinite()
,
rmNAs()
,
rmNA()
,
rmNULL()
,
sdim()
,
setPrompt()
Other jam list functions:
cPasteSU()
,
cPasteS()
,
cPasteUnique()
,
cPasteU()
,
cPaste()
,
heads()
,
jam_rapply()
,
list2df()
,
mergeAllXY()
,
mixedSorts()
,
rbindList()
,
relist_named()
,
rlengths()
,
sdim()
,
uniques()
,
unnestList()
sclass(list(LETTERS=LETTERS, letters=letters));
sclass(data.frame(B=letters[1:10], C=2:11))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.