3DNA Forum

Questions and answers => MD simulations => Topic started by: Mamta on January 13, 2025, 04:52:30 am

Notice: The 3DNA Forum is now a read-only archive. See the announcement.
All active support and discussions have moved to GitHub Discussions!
Title: overwritten output files
Post by: Mamta on January 13, 2025, 04:52:30 am
Dear all,
I am analyzing the helical parameters of DNA using 3700 frames from my MD simulation, with each frame having a corresponding `.bps` file. When using a `for` loop with the `analyze` command, the output is being overwritten instead of being saved in separate files for each frame.I am using x3dna-v2.4 version. Is it possible to configure the program so that it records the data for all frames without overwriting the output?                                                                                                              Thanks for your help!
Mamta
Title: Re: overwritten output files
Post by: xiangjun on January 13, 2025, 08:30:07 am
Hi Mamta,

Thanks for using 3DNA/DSSR and for posting your question on the 3DNA Forum. Could you please be specific with the command you used? The x3dna-v2.4 suite comes with a Ruby script 'x3dna_ensemble' for analyzing MODEL/ENDMDL delineated ensemble of NMR or MD structures. The x3dna-dssr program has an --nmr (--md) option that streamline the analysis of such ensembles.

Best regards,

Xiang-Jun
Title: Re: overwritten output files
Post by: Mamta on January 13, 2025, 10:00:17 am
Hi Xian- Jung,
thanks for your quick response.
I use the simple script of 3dna -
 for i in $(seq 1 3700); do
    find_pair output-filename.pdb.${i} frame${i}.bps
    analyze frame${i}.bps
done

Thanks
Mamta
Title: Re: overwritten output files
Post by: xiangjun on January 13, 2025, 10:47:57 am
Hi Mamta,

The output file name is derived from the input PDB filename, by deleting extension and add ".out". Since your PDB frame is named "output-filename.pdb.${i}", the output file will always be "output-filename.pdb.out" by replacing ".{i}" with ".out". You could name your PDB frame "output-${i}.pdb" and the corresponding output file will be "output-${i}.out".

Have a look of the C source code, and the x3dna_ensemble script (x3dna_ensemble analyze -h). Overall, the x3dna-v2.4 support for MD analysis is limited. There is also do_x3dna (https://do-x3dna.readthedocs.io/en/latest/) -- I'm not sure if it is still actively maintained.

I'm in the process of incorporating x3dna-v2.4 features into DSSR (Free academic license available from CTV (https://inventions.techventures.columbia.edu/technologies/dssr-an-integrated--CU20391)). Further improvement for MD support will be implemented in DSSR.

Best regards,

Xiang-Jun
This forum is archived. Please post new questions on GitHub Discussions!