3
$\begingroup$

We have a website and an analytics tool that collects traffic information to the website. The two variables that are collected are Page Views (number of pages a user has seen) and Visits (number of sessions).

Recently we had an annual event, and our analytics code got compromised and damaged our visits count. Luckily, we have our page view count.

We would like to know the approximate number of visits for that period where we lost the data. So, what I did was collect information for all similar events in order to find a model that best fits the data of the compromised event.

The following is the data format:

https://www.dropbox.com/s/j399trqtf5o07co/Screenshot%202015-09-24%2012.45.16.png?dl=0

Each event information is 7 days long, which lists the month the event was held, its respective PageView and Visits information, and an Event identifier.

The following is the page view data for the current event that we recorded (with compromised visits data):

1 143,440,940

2 87,308,548

3 68,382,129

4 103,318,220

5 48,128,641

6 50,196,344

7 46,599,617

How would I approach this problem?

I was not sure how to 'feed' the new data into the historical data and identify how one can then build the visits data. I also tried to normalize the historical data by taking the sum of information in the last 7 days, and getting a percentage for each of the dates.

$\endgroup$
1
$\begingroup$

I would take a simple approach. From past events, determine the typical ratio of page views to visits by day (because it's possible this is different for day 1 of an event than day 4 or day 7). Apply this ratio to your data.

By "typical ratio", I mean the median -- this will eliminate outliers that may be very high or low due to various circumstances.

$\endgroup$
  • $\begingroup$ I want to say that your advice to include the median helped significantly. Using hourly granularity, I achieved 99% accuracy when I back-tested with the scrapes of available data before the compromise occurred. $\endgroup$ – Adib Sep 28 '15 at 22:48
  • 1
    $\begingroup$ I selected your advice as the best solution since it helped guide me to find the best solution. What I did is built a modified closest-neighbor algorithm that measures the best possibilities based on historical data, including the spikes and drops. Thank you again! $\endgroup$ – Adib Sep 28 '15 at 22:49
1
$\begingroup$

I would prefer to plot a graph of number of visits against number pages, on the basis of past data. You must have the data of long period of time. Take number of visits as independent variable and number of pages seen as dependent variable. Now according to the graph see which regression equation you can fit. Then fit that equation to the data. Now you would get equation of 'number of pages seen' in terms of 'number of visits'. Then you can find approx number of pages seen for the the number of visits you mentioned above by simply putting that number in the equation. You can easily get the info about how to identify the equation from the graph and how to fit the equation from the internet.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.