Learn R Programming

netrankr (version 1.2.4)

incomparable_pairs: Incomparable pairs in a partial order

Description

Calculates the fraction of incomparable pairs in a partial order.

Usage

incomparable_pairs(P)

Value

Fraction of incomparable pairs in P.

Arguments

P

A partial order as matrix object, e.g. calculated with neighborhood_inclusion or positional_dominance.

Author

David Schoch

See Also

comparable_pairs

Examples

Run this code
library(igraph)
g <- sample_gnp(100, 0.1)
P <- neighborhood_inclusion(g)
comparable_pairs(P)
# All pairs of vertices are comparable in a threshold graph
tg <- threshold_graph(100, 0.3)
P <- neighborhood_inclusion(g)
comparable_pairs(P)

Run the code above in your browser using DataLab