Invalid inputs? Invalid signature or other data?
First of all if any of the above parameter is invalid then the transaction wont be created on first place. The transaction will be discarded.
To create transaction :
1) Valid Vin and Vout that will be determined by algorithm itself
2) Creating raw transction using txid
3)Signning the transcation (which will be needing your pvt key)
4)Sending the transaction to mempool for verification.
If you manage to reach step 4 then your transaction will possibly get confirmed but for sure it will be sent to mempool. Now its over the miner to confirm or not confirm your transaction.
If you want to make your unconformed transaction as conformed:
one can redo the same transcation with little more transaction fee. If miner is to mine your particular transaction and make it confirm than he needs to confirm all of your earlier tranasctions as well.
Now to answer your question about making your unconformed transaction as invlaid you dont need to do anything for that, after some period of time for your transaction in being in mempool, still unconformed, get revert back to your wallet address