Your total calculated field is an aggregate because it's adding two SUMs (SUM([V1])+SUM([V2])), so the return values of the KPI all calculation must both be aggregates. You can fix this by changing [Profit] to SUM([Profit]) as shown below:
IF [KPi]='profit' THEN
Next, I'd suggest that, instead of including the CY YTD field as part of the CY calculated field, simply drag that up to filters and select only the "True" option.
Finally, modify CY to look like this:
IF [time frame]='1' THEN
I believe that should fix the problem.
See attached workbook.
AGg_non agg.twbx 1.2 MB