# functionality of get.decluttered() is conveniently provided in citation.counts()
# Data set: ojtcata
# Get declutter matrix for comparison of Product 2 vs. average of all products
data(ojtcata)
oj2.v.all <- citation.counts(ojtcata, product.name = "2", product.col = 2,
attribute.col = 4, results.col = 5:25, comparison = "average")
oj2.v.all$declutter
# same as
p2.declutter <- get.decluttered(x = c(oj2.v.all$P1), n.x = oj2.v.all$Pn,
y = c(oj2.v.all$C1), n.y = oj2.v.all$Cn)
(p2.declutter <- matrix(p2.declutter, nrow = nrow(oj2.v.all$P1)))
Run the code above in your browser using DataLab