Dependencies

The software versions are provieded in the SessionInfo at the end. mclust and hdf5r is required.

library(mclust)
    __  ___________    __  _____________
   /  |/  / ____/ /   / / / / ___/_  __/
  / /|_/ / /   / /   / / / /\__ \ / /   
 / /  / / /___/ /___/ /_/ /___/ // /    
/_/  /_/\____/_____/\____//____//_/    version 5.4.5
Type 'citation("mclust")' for citing this R package in publications.

Attaching package: ‘mclust’

The following object is masked _by_ ‘.GlobalEnv’:

    plot.MclustDA
source("R/utils/reader.R")
source("R/utils/mclust_plot.R")
source("R/utils/hdfrw.R")

Read in the data

cell_line = "mESC"
lab = c(rep('g0/g1', 96), rep('s', 96), rep('g2/m', 96))
cyclum <- hdf2mat('cyclum-pseudotime.h5')

Train an mclust GMM to evaluate the accuracy.

groundtruth <- vector(length = length(lab))
groundtruth[lab == 'g0/g1'] = 1
groundtruth[lab == 's'] = 2
groundtruth[lab == 'g2/m'] = 3

mclust_result <- MclustDA(cyclum, groundtruth, verbose = F)
plot(mclust_result, col=c('#FF0000', '#00FF00', '#0000FF'), what="scatterplot")
title(paste('cyclum Accuracy:', round(1 - summary(mclust_result)$err, 3)))

sessionInfo()
R version 3.5.2 (2018-12-20)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Debian GNU/Linux 10 (buster)

Matrix products: default
BLAS/LAPACK: /usr/lib/x86_64-linux-gnu/libmkl_rt.so

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C               LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8    LC_PAPER=en_US.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C             LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] hdf5r_1.3.0  mclust_5.4.5

loaded via a namespace (and not attached):
[1] bit_1.1-14     compiler_3.5.2 R6_2.4.0       t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