@dream-mind opened this Issue on May 2nd 2018

IF Site has more than one domain(or use both android and iOS native SDK),exit_rate & bounce_rate may more than 100%

because /core/DataTable/Row.php use sum operation´╝îBut for the percentage value can't use sample sum operation, should use original molecular and denominator.

@huang0808 commented on May 22nd 2018

@YueminJi I met this issue, how fix it?

@huang0808 commented on May 30th 2018

@Sija have you ways to fix the issue? thanks very much.

@dream-mind commented on May 30th 2018

@huang0808 here is my Temporary solutions
change core/DataTable/Row.php File like this

public function sumRow(Row $rowToSum, $enableCopyMetadata = true, $aggregationOperations = false)
        foreach ($rowToSum as $columnToSumName => $columnToSumValue) {

            // fix bounce_rate
            if($columnToSumName == 'bounce_rate'){
                $total_entry_bounce_count = (int)$this->getColumns('storage')['entry_bounce_count']+(int)$rowToSum->getColumns('storage')['entry_bounce_count'];
                $total_entry_nb_visits = (int)$this->getColumns('storage')['entry_nb_visits']+(int)$rowToSum->getColumns('storage')['entry_nb_visits'];
                $bounce_rate = number_format($total_entry_bounce_count/$total_entry_nb_visits,2);
               return $this->setColumn($columnToSumName, $bounce_rate);
            // fix exit_rate
            if($columnToSumName == 'exit_rate'){
                $total_exit_nb_visits = (int)$this->getColumns('storage')['exit_nb_visits']+(int)$rowToSum->getColumns('storage')['exit_nb_visits'];
                $total_nb_visits = (int)$this->getColumns('storage')['nb_visits']+(int)$rowToSum->getColumns('storage')['nb_visits'];
                $exit_rate = number_format($total_exit_nb_visits /$total_nb_visits,2);
               return $this->setColumn($columnToSumName, $exit_rate);

            if (!$this->isSummableColumn($columnToSumName)) {
@huang0808 commented on June 1st 2018

@YueminJi thanks a lot, work well.

@sgiehl commented on November 13th 2022 Member

This one should have meanwhile be fixed.

This Issue was closed on November 13th 2022
Powered by GitHub Issue Mirror