I have always purchased what i would consider good factory rifles and then had the trigger worked on had them bedded, and free floated, possibly the crown recut etc..and have ended up with some real nice shooting rifles..then when they are ready for a new barrel off to the smith for truing etc...and a new match barrel kinda a semi custom route to go and well below cost of many of many rifles that don't shoot as well.
However this doesn't always work out. I picked up a factory 338 lapua and had nothing but issues with it bought it because I thought I might be able to cheat and get what I wanted for a lot less coin than a custom...worst decision I have made in awhile. I got it quick no doubt, but with all the trouble I had trying to get it to function I would have been better off waiting. Now it is out for a new barrel , bedding, truing, and I am missing shoots because I tried to skate by with a factory rifle for a custom situation in this case I should have ordered a custom and waited.
Either way I am still well below the 5k mark even with optics I can't justify spending that kind of money on a rifle when I have kids to feed and put shoes on