The only way to escape loss of your altcoin is by hodling. As long as you don't sell, the price is nothing but a number on the paper.
Avoid what? because usually losing altcoin is synonymous with hacking our wallet by someone we don't know, but you say this with just a word without a more complete explanation for it.