Summarize a directory with PowerShell
You are running your select twice and saving an unused Average from your Select-Object

gci -r -ea Si `
| group { if ($_.PSIsContainer) {""} else {$_.Extension} } `
| sort Count -desc `
| ft Name, Count, @{n="SizeMB"; e={"{0:N1}" -f (($_.Group | measure Length -Sum).Sum / 1MB)};a="right"} -Auto


You have to move the Group Measurement to the FT line from the Select. 

If you want this a little more readable, you can pull the formatting HashTable out of the pipeline:

$sizeMB = @{n="SizeMB"; 
            e={"{0:N1}" -f (($_.Group | measure Length -Sum).Sum / 1MB)};
            a="right"}

gci -r -ea Si `
| group { if ($_.PSIsContainer) {""} else {$_.Extension} } `
| sort Count -desc `
| ft Name, Count, $sizeMB  -Auto