I have a 6 year old Sony Vaio V series which has always been plugged in where possible. I even left it on mains power for weeks on end if using it at home.
Battery and power options were set to Vaio Optimised since day one.
The battery is still good for 2.5 to 3.5 hours use dependant on what I am doing.
Answer - Plug it in whenever you can.
This thread is now locked and can not be replied to.