Somewhere in the beginning of this year I wrote about the sunk cost fallacy. In short: if you're deciding on something, you shouldn't take the past investment into account.
There is one refinement to this topic I'd like to point out: while you should dismiss previous investments, you should take all the possible value you're going to get out of it into calculation.
This time, let's roll in an (extremely simplified) example:
Let's say you've already invested €2.000 in feature A you're building. You still need €2.000 to finish it. The value that feature A will deliver is €3.500.
There's also feature B. No work has gone into it yet, but it is estimated on €1.500. The value you could get out of it is €2.500.
On a first look, it would feel the most logical to go for feature B: returns the same amount of money for a smaller investment (because net result is €1.000 for B, versus €500 for A). But all effort made in the past doesn't matter anymore: the work is done and the money is lost. Irreversible. So if you would look at the problem that way, the scale tips over to feature A: you'll earn €1.500 instead of €1.000.