Create an object of class "rankings" from tricot ranking data.

rank_tricot2(data, id, items, input, strict = FALSE, ...)

Arguments

data

a data.frame with columns specified by items and input values

id

an index of data indicating the id column

items

a character or numerical vector for indexing the column(s) containing the item names in data

input

a character or numerical vector for indexing the column(s) containing the values in data to be ranked

strict

logical. If TRUE, reject missing or duplicate id/item/rank records and require positive integer ranks with no ties within an id. Defaults to FALSE to preserve the legacy warning-and-skip behaviour

...

additional arguments passed to methods. See details

Value

a PlackettLuce "rankings" object, which is a matrix of dense rankings

References

van Etten J., et al. (2016). Experimental Agriculture, 55(S1), 275–296. doi:10.1017/S0014479716000739

See also

Author

Kauê de Sousa

Examples


library("gosset")

R = nicabean$trial

R = R[R$trait == "Vigor", ]

names(R)

R = rank_tricot2(R, id = "id", items = "item", input = "rank")