Apparently, you have a sub summary layout part with "when sorted by income".
Do you then have at least one other sub summary layout part based on a different field? Such as location or region that results in groups of records for North, East, South, and West?
With sorting already grouping your records for sub summary parts, I don't see the reason for using the If functions.
I would think that GetSummary ( SummaryField ; BreakField ) would be all that you need. When the value of BreakField is "income" the subtotal returned by this field will be based on the group records where BreakField = "income". When the value of BreakField is a different value, you get a different subtotal based on that value.
But then there is this statement:
This was pretty easy to set up and display the data in the columns I needed.
Subsummary layout parts organize data into rows, not columns so I find myself wondering if you are trying to list sub totals in a row with sub total computed from a different group of records--that is something that cannot be done with getSummary and needs a different method.
So I suggest taking another swing at describing the format of your report.