nction(x) length(setdiff(x,comp
A.K.
- Original Message -
From: Yung Chih Ou
To: r-help
Cc:
Sent: Wednesday, December 26, 2012 7:37 AM
Subject: [R] data comparison
Dear all:
I have six vector from six DIF detection results.
as below:
> difMH[[100]]$DIFitems
[1] 1 9 19
Hello,
Sorry, my previous post is wrong, to make of it a matrix use
do.call(cbind, lapply(idx, function(i) difMH[[i]]$DIFitems))
Hope this helps,
Rui Barradas
Em 26-12-2012 14:44, Rui Barradas escreveu:
Hello,
Try the following.
# 1.
idx <- seq(50, 100, by = 10)
mat <- matrix(difMH[idx]$DIF
Hello,
Try the following.
# 1.
idx <- seq(50, 100, by = 10)
mat <- matrix(difMH[idx]$DIFitems, ncol = length(idx))
# 2.
comp <- c(1, 9, 21, 22, 25, 30, 34, 38)
hit <- lapply(difMH[idx], function(x) length(intersect(x$DIFitems, comp)))
falarm <- lapply(difMH[idx], function(x) length(setdiff(x$DI
3 matches
Mail list logo