A negative index there is just like using a negative list index in Python. -1 means the highest index, -2 the one down from that and so on. In this case since it was wanted to remove the couple of unoccupied orbitals down from the highest one. So that was a convenient way to specify them rather than having to know the total orbitals and compute a 0 based index (which would be valid too). The orbitals removed were known from the molecule itself to play only a very small part in the overall behavior.
As to doing this for others, well you really need to take great care. You can see plots here for BeH2 orbital reduction, which though done a long time ago, and the code used there is now out of date, are still valid. Freezing the core orbitals is always safe to do though.