> library(MultiAssayExperiment)
> mat = matrix(1:6, ncol=3, dimnames=list(c("a", "b"), c("d", "e", "f")))
> pdat = data.frame(x=1:3, row.names = colnames(mat))
> MultiAssayExperiment(ExperimentList=list(A=mat), pData=pdat[1, , drop=FALSE])
Error in if (dim(object)[1] > 0 && is.null(rownames(object))) { :
missing value where TRUE/FALSE needed
In addition: Warning messages:
1: In MultiAssayExperiment(ExperimentList = list(A = mat), pData = pdat[1, :
sampleMap not provided, trying to generate sampleMap...
2: In .generateMap(pData, ExperimentList) : Data from rows:
NA - e
NA - f
dropped due to missing phenotype data
## from session_info():
## MultiAssayExperiment * 0.101.37 2016-07-14 Github (vjcitn/MultiAssayExperiment@f60de4b)
OK this is a corner case, but you never know: