filter_extra_attrs | R Documentation |
Filter interactions by extra attribute values
filter_extra_attrs(data, ..., na_ok = TRUE)
data |
An interaction data frame with extra_attrs column. |
... |
Extra attribute names and values. The contents of the extra attribute name for each record will be checked against the values provided. The check by default is a set intersection: if any element is common between the user provided values and the values of the extra attribute for the record, the record will be matched. Alternatively, any value can be a custom function which accepts the value of the extra attribute and returns a single logical value. Finally, if the extra attribute name starts with a dot, the result of the check will be negated. |
na_ok |
Logical: keep the records which do not have the extra attribute. Typically these are the records which are not from the resource providing the extra attribute. |
The input data frame with records removed according to the filtering criteria.
extra_attrs
has_extra_attrs
extra_attrs_to_cols
with_extra_attrs
extra_attr_values
cl <- post_translational(
resources = "Cellinker",
fields = "extra_attrs"
)
# Only cell adhesion interactions from Cellinker
filter_extra_attrs(cl, Cellinker_type = "Cell adhesion")
op <- omnipath(fields = "extra_attrs")
# Any mechanism except phosphorylation
filter_extra_attrs(op, .SIGNOR_mechanism = "phosphorylation")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.