Re: [AMBER] How to do analysis on specific frames in cpptraj?

From: Daniel Roe via AMBER <amber.ambermd.org>
Date: Tue, 21 Feb 2023 08:20:05 -0500

Hi,

Right now you can just do it via multiple 'trajin' statements and
specifying the beginning and ending frames:

parm A.prmtop
trajin A.nc 1 1
trajin A.nc 78 78
trajin A.nc 100 101
trajin A.nc 170 170
watershell ...

You could also do it via a 'for' loop:

parm A.prmtop
for FRAME in 1,78,100,101,170
  trajin A.nc $FRAME $FRAME
done
watershell ...

In the future I hope to make it easier to do via a single 'trajin'
statement, but the above should work for now. Hope this helps,

-Dan

On Tue, Feb 21, 2023 at 7:03 AM XP Chen via AMBER <amber.ambermd.org> wrote:
>
> I want to do some analysis (here is `watershell`) on some specific frames.
>
> I use a not-easy way as follows. However, it will create new trajectory files, and make it not convenient for large trajectories. Is there any elegant way to do analysis on specific frames which do not fulfill `<start> <stop> <offset>` in `trajin`?
>
> 1. First split the trajectory
> ```
> parm A.prmtop
> trajin A.nc
>
> trajout B1.nc netcdf onlyframes 1,78,100,101,170
> trajout B2.nc netcdf onlyframes 8,82,88,99,120,125
> run
> ```
>
> 2. Then reload the new trajectory and do the analysis
> ```
> parm A.prmtop
> trajin B1.nc
>
> watershell :5.SG out wa.out lower 3.5 upper 5.0 :WAT
> run
> ``
>
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org
> http://lists.ambermd.org/mailman/listinfo/amber

_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Tue Feb 21 2023 - 05:30:03 PST
Custom Search