I'm sorry, I forgot to put the DAX formulas. I hadn't included them since I intended to add a PBIX file, but I couldn't find a way to attach it to the post.
Here is the DAX formula for realized hours:
Realized hours =
VAR LastVisibleDate = MAX(Dates[Date])
Var FirstVisibleDate = MIN(Dates[Date])
Var LastDateWithHours = CALCULATE(MAX('Table'[Dates]),REMOVEFILTERS())
Var Result = IF(FirstVisibleDate <= LastDateWithHours, CALCULATE(SUM('Table'[Hours]),dates[date] <= LastVisibleDate))
return Result
Here is the DAX formula for estimated hours:
Estimate Hours =
VAR LastVisibleDate = MAX('Table'[End Date])
Var FirstVisibleDate = MIN(Dates[Date])
VAR DayBetweenDates = DATEDIFF(FirstVisibleDate,LastVisibleDate,DAY)
return SELECTEDVALUE('Table'[Total Estimate Hours])/DayBetweenDates
The sample data are identical to my source data, they have been ultra simplified to facilitate finding a solution.
The hours data have been aggregated for performance reasons. Initially, it was a table with multiple rows per day per user per project.
The projects data was a table by itself. It was combined with the previous table to facilitate the application of filters and measurements. This seemed to be the best decision in terms of performance, but I haven't measured it until now because of the concern initially presented.