cset-class: The CSet class

Description Details Slots

Description

Creates a 'cset' object that represents a control set of TF-gene interactions. It inherits from the 'set' class. It is composed of 4 slots: a 2-column character dataframe named 'ris' (regulatory interactions) and a character vector named 'tfs' (transcription factors) inherited from the Set class, a character attribute 'type' and a character attribute 'id'.

Details

#' @title The Set class #' @description Creates a 'set' object that represents a set of TF-gene interactions. #' It is composed of 2 slots: a 2-column character dataframe named 'ris' (regulatory interactions) and #' a character vector named 'tfs' (transcription factors). #' #' @slot ris A 2-column character dataframe of TF-gene interactions with colnames = c("tf.symbol", "gene.symbol") #' @slot tfs A character vector of TF names #' @import dplyr #' @export

setClass( "set", slots = list( ris = "data.frame", tfs = "character" ) )

# setValidity("set", function(object) # ## TODO # ## tfs have to be ordered and unique # )

#' @title Constructor function of a set object. #' @description Constructor function of a set object. #' @param ris A 2-column character dataframe of TF-gene interactions. #' @param tfs A character vector of TF names. #' @return A 'set' object. #' @export

set <- function(ris, tfs) stopifnot(is.data.frame(ris)) stopifnot(is.character(tfs)) ris tfs <- unique(sort(tfs))

new("set", ris = ris, tfs = tfs)

Slots

ris

A 2-column character dataframe of TF-gene interactions with colnames = c("tf.symbol", "gene.symbol")

tfs

A character vector of TF names

type

A character in c("positive", "negative")

id

A character name


rioualen/NetworkEval documentation built on April 10, 2021, 5:22 a.m.