Moodle and Google Analytics

Post on 06-May-2015

9.643 views 0 download

Tags:

description

Standard Google Analytics reporting takes the URL from the page to track the views. With Moodle this means that it is not possible to easily track which activity URL belongs to what course within the Analytics. This presentation looks at the work done to help address this issue and at the test of the solution during the Ireland & UK Moodlemoot. Gavin Henrick was the original founder of this idea and together we found a solution.

Transcript of Moodle and Google Analytics

MOODLE AND GOOGLE ANALYTICSBAS BRANDS

I am a part freelance part employed webdeveloper. I enjoy programming with Moodle because of it’s excellent community and truly open source character

BAS BRANDS

INTRODUCTION

Standard Google Analytics reporting takes the URL from the page to track the views.

With Moodle this means that it is not possible to easily track which activity URL belongs to what course within the Analytics.

This presentation looks at the work done to help address this issue and at the test of the solution during the Ireland & UK Moodlemoot.

Gavin Henrick was the original founder of this idea and together we found a solution.

Advanced features :

- User behavior

- Custom charts

- Mailing of reports

- Pageload speed

- Traffic sources

- Demographics

- Mobile usage

- Visitor Flow

- Live statistics

ABOUT GOOGLE ANALYTICS (GA)

<script type="text/javascript">

var _gaq = _gaq || [];

_gaq.push(['_setAccount', 'UA-000000-4']);

_gaq.push(['_trackPageview']);

(function() {

var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;

ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';

var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);

})();

</script>

1. Register on:

http://google.com/analytics

2. Add your website

3. Receive the JavaScript code snippet

4. Embed in your Moodle theme layout files

HOW TO GET GOOGLE ANALYTICS FOR MOODLE

SAMPLE ANALYTICS PAGE ON CONTENT

SAMPLE OF A STANDARD GA REPORT OF MOODLE

- Which course is the course with id = 13 ?

- In what course was the dialogue activity visited?

- What course category was visited most?

DEFAULT MOODLE REPORT IS HARD TO READ

SAMPLE OF A GOOGLE ANALYTICS REPORT OF WORDPRESS

- I can see which articles are viewed

- I can break it down into year, month, day

- I could create graphs of most viewed articles in May

DEFAULT WORDPRESS REPORT IS EASY TO READ

STANDARD MOODLE URL’S

- Which section is that resource linked in?

- Which course is that resource part of?

- Which category is that course in?

- Was it a student or an admin who clicked that link?

QUESTIONS WHEN LOOKING AT STANDARD MOODLE URL’S

THE MOODLE URL’S WE WANT

URL DESIGN

http://moodle.moodlemoot.ie/2012/delegatepack/Pre-Conference+Workshops/A+Moodle+2+Tool+Guide+for+Teachers

Category

Course Short name

Section name

Activity name

(Activity type)

STANDARD ANALYTICS GRAPHS USING THESE URLS

STANDARD ANALYTICS GRAPHS USING THESE URLS

NOW THE FUN STARTS!COURSE OVERVIEW

NOW THE FUN STARTS!COURSE OVERVIEW

CREATING CUSTOM DASHBOARDS

COURSE STATISTICS

COURSE STATISTICS

USER FLOW

- JS snipped loaded by our browser

- setAccount var

- trackPageview var

- https://developers.google.com/analytics/devguides/collection/gajs/?hl=nl

ANOTHER LOOK AT THE GA JAVASCRIPT CODE

FEED A URL TO THE JAVASCRIPT SNIPPET

Code snippet that shows part of the URL design

- Section

- Activity type

- Activity name

- Action type

GENERATE A CUSTOM URL IN PHP

GENERATE A CUSTOM URL

THE FUTURE OF THIS PROJECTPage related variables

- category, role, department, uid ??

Logging of events

- activity completion, user created

Grades

- get grade statistics on course

Get GA data back into Moodle

- the emailed report

- creating your own graphs in Moodle

GET GA DATA BACK

GET INVOLVEDMore info on what has been done:

Blogpost by Gavin Henrick

http://www.somerandomthoughts.com/blog/2012/04/18/ireland-uk-moodlemoot-analytics-to-the-front/

Blogpost by Bas Brands

http://basbrands.nl/2012/04/18/google-analytics-with-moodle/

More info on

The GA JS snippet

https://developers.google.com/analytics/devguides/collection/gajs/?hl=nl

Google analytics Query explorer

http://ga-dev-tools.appspot.com/explorer/?csw=1

Getting Google analytics data using php

https://code.google.com/p/gapi-google-analytics-php-interface/

http://www.codediesel.com/php/reading-google-analytics-data-from-php/

CONTACT US

Bas Brands

bmbrands@gmail.com

Twitter: bmbrands

Gavin Henrick

ghenrick@gmail.com

Q&A / DISCUSSION

What about privacy?

Alternatives?

• Woopra

• Clicky

• Piwik (open source)

• Open Web Analytics (open source)

Read more: http://imimpact.com/web-stats-alternatives-to-google-analytics/

What about performance?