##################################################
## Using Gaussian Data
##################################################
## Load predefined data
data(gmG)
## Define the score object
score <- new("GaussL0penObsScore", gmG$x)
## Score of the true underlying DAG
score$global.score(as(gmG$g, "GaussParDAG"))
## Score of the DAG that has only one edge from 1 to 2
A <- matrix(0, ncol(gmG$x), ncol(gmG$x))
A[1, 2] <- 1
score$global.score(as(A, "GaussParDAG"))
## (Note: this is lower than the score of the true DAG.)
Run the code above in your browser using DataLab