                 alertService.add("danger", "Failed to get unit progress class statistics", 6000)
               $scope.classStats = {}
       $scope.poaView.activeTab = tab
+      eventName = if tab is 'progress' then "View Learning Progress Tab" else "Reflect on Learning Tab"
+      analyticsService.event "Stuent Feedback View - Learning Outcomes Tab", "Switched Tab", eventName
       $scope.refreshCharts()
 
     # Default tab

      $rootScope.$broadcast('ProgressUpdated')
    )

)
.directive("projectOutcomeAlignment", ->
  restrict: 'E'
  templateUrl: 'projects/partials/templates/project-outcome-alignment.tpl.html'
  controller: ($scope, $rootScope, $timeout, outcomeService, Unit, alertService, analyticsService, Visualisation) ->
    $scope.poaView = {
      activeTab: 'list'
    }
