iOpenShell » Technical questions » data extraction tips

data extraction tips

Moderators: kadir, krylov, piotr.

Page: 1

Author Post
Member
Registered: Aug 2008
Posts: 43
I thought I'd share some of the bash commands I use to pull data out of files or check on their status while they are running.

The below are for G03 (and all of these commands are defined in my .~/.bashrc).

1) To pull out only the vibrational frequencies and have them put into one column

alias grepfreq='grep "Frequencies"'

function sortfreq
{
gawk '{ print $3"\n"$4"\n"$5 }'
}

USE: grepfreq ./output-filename.log | sortfreq

2) Checking how many optimization steps have been performed (especially nice for scans and IRCs).

alias grepstep='grep "Step number"'

3) Checking how the geometry optimization is progressing.

alias grepmax='grep -A 3 "Maximum Force"'

4) Checking how many steps have been calculated in a CCSD/UCCSD frequency calculation.

alias grepccsd='grep "Leave Link 106"'
Administrator
Registered: Aug 2007
Posts: 200
Thanks wazoo, these are useful. One can just replace the arguments to use these scripts to search for something in the output of any program. I keep forgetting the syntax for awk, and now I can just look at this post to remember ;)

Page: 1

iOpenShell » Technical questions » data extraction tips