From: Tsjerk W. <ts...@gm...> - 2014-09-12 14:21:34
|
> csplit -b "%03d.pdb" test.pdbqt /^MODEL/ {0} > somelog.log > man csplit: csplit -f blabla -b "%03d.pdb" test.pdbqt /^MODEL/ {1} But you want only the first frame anyway, so no real use for csplit... sed /^ENDMDL/q my_docking.pdb | grep -v "^ROOT\|^ENDROOT\|^TORSDOF > 0\|^MODEL\|^REMARK" | sed -e 's/^ENDMDL/TER/g' > firstmodel.pdb > sed -e '/^ENDMDL/{s/^.*/TER/;q;}' -e '/^\(ROOT\|ENDROOT\|TORSDOF 0\|MODEL\|REMARK\)/d' my_docking.pdb > firstmodel.pdb ... shorter and one process running in stead of 3. Cheers, Tsjerk -- Tsjerk A. Wassenaar, Ph.D. |