Skip to content

Instantly share code, notes, and snippets.

@ISDementyev
Last active April 5, 2023 17:32
Show Gist options
  • Save ISDementyev/60eb828e09e4fdc3c110a33f439851b2 to your computer and use it in GitHub Desktop.
Save ISDementyev/60eb828e09e4fdc3c110a33f439851b2 to your computer and use it in GitHub Desktop.
Crude way to remove various residues from pdb files, including waters
#!/bin/bash
pdbs=$(ls *.pdb)
for pdb in $pdbs
do
prefix=${pdb:0:4}
grep -vf residues.txt $pdb > $prefix-ensemble-nores.pdb
done
PO4
0CT
HOH
NA
0CU
3NY
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment