As part of the course Probabilistic Graphical Models, we use the package glasso
from Friedman et al. on some random sparse graphs, and on some Markov chains.
We assume the variables follow a multinomial gaussian law. For p
variables, we generate a random sparse p * p
matrix which represents the precision matrix of the multinomial gaussian. Indeed, if the (i, j)
coefficient is null, there is no (i, j)
edge in the corresponding undirected graphical model.
We generate N
graphs ; on each graph, we test the model selection performance for different values of rho
by considering null coefficients as the targets. We define the true positive rate and false positive rate for these targets and draw ROC curves with uncertainty bounds (10, 90 quantiles) for each value of rho. This allows us to experimentally set a value of rho
given p
the number of variables and n
the number of observations.
We generate some Markov chains and test the performance of the model selection with glasso on them. We detect the critical value above which the graph is no longer connected, and visualize the evolution of the edges of the graph when rho
increases.