# S3 method
plot.bootERGM <- function(object, vars.per.page=3, cex.axis=1, cex.lab=1, cex.main=1, lwd=2){
stat.diff.mat <- t(object$bootstrap.statistics) - object$observed.statistics
par(mfrow=c(vars.per.page, 2))
for(i in 1:ncol(object$boot.mple.matrix)){
plot(stat.diff.mat[i,], type="l", main= paste("Trace of ", colnames(object$boot.mple.matrix)[i]),
ylab=" ", xlab="Iterations", cex.axis=cex.axis, cex.main=cex.main, cex.lab=cex.lab )
abline(h=0, col="red", lwd=lwd)
hist(stat.diff.mat[i,], main= paste("Density of ", colnames(object$boot.mple.matrix)[i]),
ylab=" ", xlab=" ", cex.axis=cex.axis, cex.main=cex.main, cex.lab=cex.lab)
abline(v=0, col="red", lwd=lwd)
}
#for(i in 1:ncol(x$boot.mple.matrix)){
# plot(x$boot.mple.matrix[,i], type="l", main= paste("Trace of ", colnames(x$boot.mple.matrix)[i]), ylab=" ", xlab="Iterations" )
# abline(h=x$MPLE$coef[i], col="red", lwd=2)
# hist(x$boot.mple.matrix[,i], main= paste("Density of ", colnames(x$boot.mple.matrix)[i]),
# ylab=" ", xlab=" ")
# abline(v=x$MPLE$coef[i], col="red", lwd=2)
#}
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.