Learn R Programming

interventionalDBN (version 1.2.2)

plotMaxML: Plot the performance of maximum marginal likelihood (Empirical Bayes).

Description

Make a plot of the marginal likelihood against the prior strength parameter, highlighting the value used to produce the network.

Usage

plotMaxML(output,xlab="Prior strength",ylab="Marginal likelihood", col.max="red",lty.max=3,lwd.max=1,...)

Arguments

output
The object returned from the interventionalInference function.
xlab
A label for the prior strength axis.
ylab
A label for the marginal likelihood axis.
col.max
The colour of the line highlighting the maximum.
lty.max
The line type of the highlight.
lwd.max
The line width of the highlight.
...
Other arguments, such as main, which are passed to plot.

Details

It is important to check that the Empirical Bayes calculation is doing something sensible.

See Also

interventionalDBN-package,interventionalInference

Examples

Run this code
library(interventionalDBN)
data(interventionalData)# loads interventionalData.
# Load your own data spreadsheet using myData<-read.csv("myDataFile.csv").

# Format the data for network inference
d<-formatData(interventionalData)

# EGFRi is active in conditions 2 and 4, AKTi is active in conditions 3 and 4.
# Each condition has 8 timepoints.
Z<-matrix(0,32,15)
Z[9:16,1]<-1 # EGFR (node 1) inhibited in condition 2
Z[25:32,1]<-1 # EGFR inhibited in condition 4
Z[17:24,8]<-1 # AKT (node 8) inhibited in condition 3
Z[25:32,8]<-1 # AKT inhibited in condition 4

# Perform network inference with Hamming Prior that prefers self-edges,
# and use Empirical Bayes to choose the priorStrength.
myNetwork4<-interventionalInference(d$y,d$X0,d$X1,Z,max.indeg=3,
  perfectOut=TRUE,fixedEffectOut=TRUE,
  priorType="Hamming",priorGraph=diag(rep(1,15)),priorStrength=0:10/2)
# You should always check to see if the Empirical Bayes appears to be working.
plotMaxML(myNetwork4)

Run the code above in your browser using DataLab