You can cancelLine during a lineInit depending on your business logic.
Note that this has the potential of issues on a PO if you have Purchase Contracts so it's possible that there are also similar issues on Sales Orders depending on whether NetSuite makes native internal calls that interrupt the timing of the cancelLine execution - either a setTimeout or an alternate approach would work.