Dear R users,

I have a matrix composed of lists:

m <- matrix( list(), nrow=1, ncol=3 )
m[[ 1, 1 ]] <- list("A", "B")
m[[ 1, 2 ]] <- list("A", "C")
m[[ 1, 3 ]] <- list("A", "B")

and want to get the sub-matrix where cells contain "B".
But

m[ , "B" %in% m[ 1, ], drop=F ]

as well as

m[ , "B" %in% m[ 1, ][], drop=F ]

return empty matrices.

Any ideas, hints and help will be very much appreciated!
Kind regards!
Josef

	[[alternative HTML version deleted]]

