Will vary based on where you are, but currently, in Europe, second hand prices have collapsed. You can get - just as one example - a TON of Trek Emondas for really attractive prices.
In Europe, afaik, groupsets are still incredibly expensive, but chinese ones are really questionable (i'm sitting with 2 broken er9 out of the 5 i've installed for eg, and out of the 4 sensah mech i installed last year, 1 died after 1k km). In the US, SRAM groupsets are apparently super affordable.
My point being: if you're trying to be rational with the value that your money buys, keep in mind where the second hand market is, because it's now extremely easy to build a chinese bike (with arguably appalling resale value) for more than a branded second hand bike w largely the same specs.