Of course you can exclude them, to determine whether the aircraft themselves are a viable commercial proposition for the people who bought them (the airlines) -- which they were, just as other aircraft such as the A380 today are. The people who bought A380s are happy, and will be using them for decades. Emirates would still like to buy more (and may end up buying used ones from less successful airlines)
The fact that the aircraft manufacturer spent far too much on development relative to the sales they made is of course important to the manufacturer -- or at least to whoever is financing the manufacturer, but that is a DIFFERENT question. In fact more than one question.
There is the question of whether the price they were sold to airlines for was greater or less than the incremental cost to build one aircraft. If the price was greater than the cost then there was some hope for a successful program, and they simply overspent on development and/or didn't sell enough copies.
If they were sold to airlines for less than the marginal cost then it's just an all-around manufacturing screwup that could never be solved by any amount of sales.