I ran simulations for multiple systems with same method; saved into different directories. I want to do same data analysis (gmx rms, cluster, hbond…) in all these directories. Is there a way to simultaneously apply a gmx command on multiple directories?
for dir in dir_1 dir_2 dir_n;
do
cd $dir
gmx rms/cluster/hbond .....
cd ..
done
You might want to use echo n | gmx for non-interactive user input. Here n is user choice (if any) . You can echo multiple times ( e.g., echo n1 n2 | gmx)