Learn R Programming

dcGOR (version 1.0.2)

InfoDataFrame-class: Definition for S4 class InfoDataFrame

Description

InfoDataFrame has two slots: data and dimLabels.

Arguments

Value

  • Class InfoDataFrame

Creation

An object of this class can be created via: new("InfoDataFrame", data, dimLabels)

Methods

Class-specific methods:
  • dim():
{retrieve the dimension in the object} nrow():{retrieve number of rows in the object} ncol():{retrieve number of columns in the object} rowNames():{retrieve names of rows in the object} colNames():{retrieve names of columns in the object} dimLabels():{retrieve the slot 'dimLabels', containing labels used for display of rows and columns in the object} Data():{retrieve the slot 'data' in the object}

itemize

  • str():

item

  • show():
  • as(data.frame, "InfoDataFrame"):
  • [i,j]:

Access

Ways to access information on this class:
  • showClass("InfoDataFrame"):
{show the class definition} showMethods(classes="InfoDataFrame"):{show the method definition upon this class} getSlots("InfoDataFrame"):{get the name and class of each slot in this class} slotNames("InfoDataFrame"):{get the name of each slot in this class} selectMethod(f, signature="InfoDataFrame"):{retrieve the definition code for the method 'f' defined in this class}

See Also

InfoDataFrame-method

Examples

Run this code
data <- data.frame(x=1:5, y=I(LETTERS[1:5]), row.names=paste("Term",
1:5, sep="_"))
dimLabels <- c("rowLabels", "colLabels")
# create an object of class InfoDataFrame
x <- new("InfoDataFrame", data=data, dimLabels=dimLabels)
x
# alternatively, using coerce methods
x <- as(data, "InfoDataFrame")
x
# look at various methods defined on class Anno
dimLabels(x)
dim(x)
nrow(x)
ncol(x)
rowNames(x)
colNames(x)
Data(x)
x[1:3,]

Run the code above in your browser using DataLab