this is why; that means; so it is that
A phrase used to sum up a reason or conclusion, often after an explanation. Equivalent to 'that's why' or 'so that's the situation'.
彼は昨日遅くまで働いていた。というわけで、今朝は寝坊した。
He worked late last night. That's why he overslept this morning.
つまり、計画は中止になったというわけだ。
In short, it means the plan has been canceled.
Kanji spelling using 訳; less common but seen in some writing.
Full kanji spelling with 言う; rare and somewhat stiff.
From と (quotative particle) + いう (to say) + わけ (reason, conclusion) + だ (copula). Literally 'it is the reason that one says', grammaticalized into a fixed expression.