Enter deposits as positive numbers and withdrawals as negative numbers. "Day" represents when the flow occurred (Day 1 to Total Period).
Dollar-Weighted Rate of Return (Period):
0.00%
Calculation Method: Modified Dietz
What "Dollar-Weighted Calculation Methodology" Means
The dollar-weighted calculation methodology produces a rate of return that equates the present value of all cash flows (deposits and withdrawals) and the final portfolio value to the initial investment. In finance, this is essentially the Internal Rate of Return (IRR) of the investment portfolio.
Unlike Time-Weighted Return (which eliminates the effect of cash flows), the Dollar-Weighted Return (DWR) captures the impact of the investor's timing. If you deposit a large sum of money right before the market surges, your dollar-weighted return will be higher because more of your dollars participated in the gain. Conversely, adding money before a crash lowers the DWR.
Why This Methodology Matters
Performance Assessment: It measures the actual growth of the investor's wealth, rather than just the manager's performance.
Cash Flow Sensitivity: Heavily influenced by the timing and size of external cash flows (deposits/withdrawals).
Comparison: Often compared against Time-Weighted Return to determine if market timing decisions added or subtracted value.
How It Is Calculated
While the exact calculation requires solving for an IRR polynomial, this calculator uses the Modified Dietz Method, an industry-standard approximation for DWR. The formula is:
Return = (Gain or Loss) / (Weighted Average Capital)
Gain/Loss is the Ending Value minus Beginning Value minus Net Cash Flows. Weighted Capital is the Beginning Value plus each Cash Flow weighted by the amount of time it was invested in the portfolio.
function calculateDWR() {
// 1. Get Base Inputs
var beginVal = parseFloat(document.getElementById('beginValue').value);
var endVal = parseFloat(document.getElementById('endValue').value);
var totalDays = parseFloat(document.getElementById('totalDays').value);
// Validation
if (isNaN(beginVal) || isNaN(endVal) || isNaN(totalDays) || totalDays <= 0) {
alert("Please enter valid numbers for Beginning Value, Ending Value, and Period Duration.");
return;
}
// 2. Process Cash Flows
var cashFlows = [];
// Helper to get flow values safely
function getFlow(amtId, dayId) {
var amt = parseFloat(document.getElementById(amtId).value);
var day = parseFloat(document.getElementById(dayId).value);
if (!isNaN(amt) && !isNaN(day)) {
return { amount: amt, day: day };
}
return null;
}
var f1 = getFlow('cf1_amt', 'cf1_day');
if (f1) cashFlows.push(f1);
var f2 = getFlow('cf2_amt', 'cf2_day');
if (f2) cashFlows.push(f2);
var f3 = getFlow('cf3_amt', 'cf3_day');
if (f3) cashFlows.push(f3);
// 3. Calculate Components for Modified Dietz
// Numerator: Gain = End – Start – Net Flows
var sumFlows = 0;
for (var i = 0; i < cashFlows.length; i++) {
sumFlows += cashFlows[i].amount;
}
var gain = endVal – beginVal – sumFlows;
// Denominator: Weighted Capital
// Start value is invested for the full period (Weight = 1)
var weightedCapital = beginVal;
for (var j = 0; j = 0) {
resultText.style.color = "#27ae60";
} else {
resultText.style.color = "#c0392b";
}
resultDiv.style.display = "block";
}