Dear Justin,
I am testing a umbrella simulation basing on your tutorial. But after using
your distances.pl script, i do not have the file "summary_distances.dat".
It only makes many xvg files.
I post the script below:
#!/usr/bin/perl -w
use strict;
# loop g_dist command - measure distance in each frame, write to a file
for (my $i=0; $i<=500; $i++) {
print "Processing configuration $i...\n";
system("g_dist_mpi_d -s pull.tpr -f conf${i}.gro -n index.ndx -o
dist${i}.xvg < groups.txt &>/dev/null");
}
# write output to single file
open(OUT, ">>summary_distances.dat");
for (my $j=0; $j<=500; $j++) {
open(IN, "<dist${j}.xvg");
my @array = <IN>;
my $distance;
foreach $_ (@array) {
if ($_ =~ /[#@]/) {
# do nothing, it's a comment or formatting line
} else {
my @line = split(" ", $_);
$distance = $line[1];
}
}
close(IN);
print OUT "$j\t$distance\n";
}
close(OUT);
# clean up
print "Cleaning up...\n";
for (my $k=0; $k<=500; $k++) {
unlink "dist${k}.xvg";
}
exit;
Do i have to modify the script ?
Thankful and regards,
Thu
--
gmx-users mailing list [email protected]
http://lists.gromacs.org/mailman/listinfo/gmx-users
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/Search before posting!
* Please don't post (un)subscribe requests to the list. Use the
www interface or send it to [email protected].
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists