dcd file

Issue #95 resolved
Former user created an issue

I have tried to convert pdb file to dcd format by using the function in bio3d using command line. But when I search for the file, it is not present in the directory. So, I should I create dcd file format from a pdb file? please let me know.639

Comments (2)

  1. Lars Skjærven

    It would help if you include the code snippet you are working with. Which functions are you using? I'm guessing you would need something like:

    pdb <- read.pdb("1d1d", multi=TRUE)
    write.ncdf(pdb$xyz.models, trjfile="hey.nc")  
    

    Note that write.dcd() does not currently exist in bio3d (as far as I can see).

  2. Barry Grant

    I am going to close this issue as it is updated in Issue #96.

    I will add that to do this version 2.1.0 or above (as on the new 'feature_pdb_dataframe' and 'feature_visualize_dataframe' branches) entails:

    pdb <- read.pdb("2LWI", multi=TRUE)
    write.ncdf(pdb$xyz, trjfile="mytrj.nc")
    

    Whilst on previous versions 2.0.1 and below, the syntax is slightly different:

    pdb <- read.pdb("2LWI", multi=TRUE)
    write.ncdf(pdb$xyz.models, trjfile="mytrj.nc")
    
  3. Log in to comment