To the original point: No one can tell you the exact discount because there are too many variables.
A garbage
DIY installation may leave your theoretical $20k boat worth negative value as it's not worth ripping it out and putting a decent motor in it, so you have to pay to have it scrapped. A top of the line well thought out
installation may have only a modest impact on the sales price.
The underlying answer is simply supply & demand. Fewer buyers means demand is low and that drags down the prices.
It's not "alleged" that pure electric
boats have limited range. Show me an example where they have the same range at typical cruising speeds of say 80% of
hull speed. Electric can
work if you only want to get in and out of the marina but on a cruising boat most people buy with the idea of longer trips (even if they never follow thru). In order to get decent (though still lower) range, you have to accept significant reductions in cruising speed. For purist sailors, that's not a big deal but if you limit your sales to purist sailors you are back to the issue of low demand because most cruisers are not purist sailors.
Also, there is typically a holding cost if a boat doesn't sell quickly.
Maintenance, slip
fees, other
parts of the boat wear out and need replacement, so waiting 5yrs to get that decent offer is often a losing proposition.
Electric
boats are viable for certain niche uses but larger cruising boats will typically take a hit on resale value.