Skip to content

Analysis of atomistic simulation of Rab5a using BIO3D in R

SanchezBranden edited this page Aug 9, 2018 · 1 revision
  • gmx trjconv -f npt.gro -s npt.tpr -o pr.pdb -pbc mol -center

Select group 4

Select group 1

  • gmx trjconv -f md_centered.xtc -s md_0_1.tpr -o md_centered.pdb -pbc mol -center -dt 1

Select group 4

Select group 1

  • Open R studio

Click on Session

  • Set working directory to experiment

setwd("~/experiment")

  • library("bio3d")
  • pdb <- read.pdb("./pr.pdb")
  • dcd <- read.pdb("./md_centered.pdb", multi=T)
  • ca.inds <- atom.select(pdb, elety="CA")
  • xyz <- fit.xyz(fixed=pdb$xyz, mobile=dcd, fixed.inds=ca.inds$xyz, mobile.inds=ca.inds$xyz)
  • dim(xyz) == dim(dcd)
  • rd <- rmsd(xyz[1,ca.inds$xyz], xyz[,ca.inds$xyz])

plot(rd, typ="l", ylab="RMSD", xlab="Frame No.")

points(lowess(rd), typ="l", col="red", lty=2, lwd=2)

  • hist(rd, breaks=40, freq=FALSE, main="RMSD Histogram", xlab="RMSD")

lines(density(rd), col="gray", lwd=3)

  • summary (rd)
  • rf <- rmsf(xyz[,ca.inds$xyz])

plot(rf, ylab="RMSF", xlab="Residue Position", typ="l")

  • pc <- pca.xyz(xyz[,ca.inds$xyz])

plot(pc, col=bwr.colors(nrow(xyz)) )

  • hc <- hclust(dist(pc$z[,1:2]))

grps <- cutree(hc, k=2)

plot(pc, col=grps)

  • plot.bio3d(pc$au[,1], ylab="PC1 (A)", xlab="Residue Position", typ="l")

points(pc$au[,2], typ="l", col="blue")

  • cij<-dccm(xyz[,ca.inds$xyz])

plot(cij)

  • For the other simulations you can use these same steps to create analysis of the MD simulation.

Clone this wiki locally