Learn R Programming

parsec (version 1.2.7)

plot.average_ranks: Method of function plot for objects of class average_ranks

Description

From the output of the function average_ranks, the function plots the average rank and the associated rank interval, for each element of the poset.

Usage

# S3 method for average_ranks
plot(x,
    range.first = TRUE, range.col = "black", range.lty = 1,
    range.lwd = 1, type = "p", ylim = c(nrow(x), 1),
    xlab = "", ylab = "Average rank", pch = c(16, 3, 3),
    col = "black", cex = c(1, 1, 1), ...
)

Arguments

x

An object of class average_ranks.

range.first

A boolean attribute to specify whether the interval is plotted in background (TRUE) or in foreground (FALSE).

range.col

Color of the interval.

range.lty

The line type to represent the range; the values are the same of the attribute lty in the plot.default function.

range.lwd

Width of the lines representing the range.

type

Attribute of the function plot.default, here "p" by default.

ylim

Attribute of function plot.default, here c(max(x$sup), 1) by default (this way, the Y-axis is reversed, so that rank 1 corresponds to "best").

xlab

Attribute of the function plot.default, here "" by default.

ylab

Attribute of the function plot.default, here "Average rank" by default.

pch

Attribute of the function plot.default, here c(16, 3, 3) by default. This method uses the matplot function to plot the average ranks and their range. The first value refers to the point character of the average rank, the other two to the point characters of the range.

col

Attribute of the function plot.default, here "black" by default. The average ranks and their ranges are of the same color, but similarly to pch, users can provide a vector of different colors.

cex

Attribute of the function plot.default, here c(1, 1, 1) by default.

...

Other arguments of the function plot.default.

See Also

average_ranks, plot.default, matplot

Examples

Run this code
profiles <- var2prof(varlen = c(3, 2, 4))
Z <- getzeta(profiles)
res <- average_ranks(Z)
plot(res)

Run the code above in your browser using DataLab