## Activities: Engagement analytics

mod_engagement
Maintained by Adam Olley
This is the indicator component of the Engagement analytics suite. Make sure to also get the report and block!
11k
484
1
Moodle 2.2, 2.3, 2.4, 2.5

Moodle Engagement Analytics for Moodle 2

* IMPORTANT *

This plugin is useless on its own, you should also get the report and block plugins that are part of the set.

* CREDITS *

Code: Adam Olley <adam.olley@netspot.com.au>
Code: Ashley Holman <ashley.holman@netspot.com.au>
Concept: Phillip Dawson <phillip.dawson@monash.edu>
Indicator Algorithms: Phillip Dawson <phillip.dawson@monash.edu>

### Sets

This plugin is part of set Engagement Analytics.

### Contributors

Adam Olley (Lead maintainer): Developer
Ashley Holman: Developer
Phillip Dawson: Concept & Algorithms
Danny Liu: Developer
Please login to view contributors details and/or to contact them

### Comments

Show comments
• Wed, May 21, 2014, 2:03 PM
Hi Adam
We'd like to continue to use this plugin when we upgrade to Moodle 2.6 but the 2.7 version fails the compatibility test. The 2.5 version also fails. Will there be a version for 2.6? If no, we will withdraw it until our December upgrade to 2.7. Many thanks
• Wed, May 21, 2014, 2:23 PM
Hi Caitlyn,

I could look at making a 2.6 version available. Are you able to provide some more detail on how its failing exactly on 2.6 (it may well be the case I'll see the problem straight away when I try it, but doesn't hurt to ask ;) )
• Wed, May 21, 2014, 11:36 PM
Hi Adam,

I am on the same boat as Caitlyn, installed 2.5 version of report and mod of engagement and 2.6 version of block of engagement, but it didn't work in my 2.6.2 moodle env.

The error that I got is:

When I go into Plugins>>Reports>>Engagement Analytics, I get the following error….
Manage indicators
Coding error detected, it must be fixed by a programmer: PHP catchable fatal error
More information about this error
Debug info: Argument 1 passed to report_engagement_renderer::display_indicator_list() must be an instance of plugin_manager, instance of core_plugin_manager given, called in [dirroot]/report/engagement/manage_indicators.php on line 73 and defined
Error code: codingerror
Stack trace:
• line 393 of /lib/setuplib.php: coding_exception thrown
• line 119 of /report/engagement/renderer.php: call to default_error_handler()
• line 73 of /report/engagement/manage_indicators.php: call to report_engagement_renderer->display_indicator_list()

Many thanks,
Bei
• Mon, May 26, 2014, 8:34 AM
Hi all,

Latest version uploaded just now finally supports mod_assign in the assessment indicator. Thanks go to eugeneventer for his pull request.
• Tue, May 27, 2014, 3:09 AM
Hi Adam,

Our Moodle is using Oracle 11g, so I got the following error when I go to course->report-engagement analytics:

Debug info: ORA-00933: SQL command not properly ended

SELECT rawdata
FROM m_engagement_cache
WHERE indicator = :o_param1
AND courseid = :o_param2
AND timestart = :o_param3
AND timemodified > :o_param4
ORDER BY timemodified DESC
LIMIT 1
[array (
'o_param1' => 'assessment',
'o_param2' => 482,
'o_param3' => '1335844800',
'o_param4' => 1401127527,
)]
Error code: dmlreadexception
Stack trace:

line 443 of /lib/dml/moodle_database.php: dml_read_exception thrown
line 271 of /lib/dml/oci_native_moodle_database.php: call to moodle_database->query_end()
line 1122 of /lib/dml/oci_native_moodle_database.php: call to oci_native_moodle_database->query_end()
line 1428 of /lib/dml/moodle_database.php: call to oci_native_moodle_database->get_records_sql()
line 1056 of /lib/dml/oci_native_moodle_database.php: call to moodle_database->get_record_sql()
line 1501 of /lib/dml/moodle_database.php: call to oci_native_moodle_database->get_record_sql()
line 156 of /mod/engagement/indicator/indicator.class.php: call to moodle_database->get_field_sql()
line 132 of /mod/engagement/indicator/indicator.class.php: call to indicator->get_cache()
line 111 of /mod/engagement/indicator/indicator.class.php: call to indicator->get_risk_for_users()
line 94 of /report/engagement/index.php: call to indicator->get_course_risks()

The fix I have put in mod/engagement/indicator/indicator.class.php is:

$rawdata =$DB->get_field_sql('
! SELECT rawdata from
! (SELECT rawdata
FROM {engagement_cache}
WHERE indicator = ?
AND courseid = ?
AND timestart = ?
AND timemodified > ?
! ORDER BY timemodified DESC)
! where rownum = 1', \$params);

Not sure whether you can integrate it into your plugins or not. Just wanted to let you know.

Thanks,
Bei
• Tue, May 27, 2014, 3:12 AM
Adam,

Other than that error, the engagement analytics plugins version 2.6 is working fine in our Moodle 2.6.2 .
• Tue, Jun 24, 2014, 2:25 AM
Thanks for the updates Adam. I now have the mod, report, and block running on Moodle 2.6. I think these plugins are useful and have great potential so thank you for contributing them.

I have a number of dummy accounts enrolled on a course for testing purposes, they have example info on their profile pages and profile pictures (edited by me as an admin) but I've never logged in under those accounts. The course has forums, chats, and wikis on it.

From the sitewide config page: moodle/report/engagement/manage_indicators.php?contextid=1 I see that it only monitors Assessment (presumably pushed grades?), Forum, and Login activity. Are there any plans to include other core Moodle activity modules?

Also, it'd be nice to have some documentation collated somewhere so that it's easier to get started and to understand how it works, e.g. How does it calculate the percentages it shows?

Thanks in advance
• Tue, Jun 24, 2014, 8:03 AM
Hi Matt,

There are no immediately plans for me to make additional indicators right now. That said, nothing stopping people making their own to share, like Dan Marsden did for the attendance module:
https://github.com/danmarsden/moodle-engagementindicator_attendance

As for developer documentation, I did write some up when this was released, you can find it here:
http://docs.moodle.org/dev/report/analytics/api
It includes a couple basic examples of things that I hope are helpful
• Mon, Oct 20, 2014, 7:38 PM
Hi, I am wondering is there any more recent documentation available for writing additional plugins. I really need to have an indicator based on downloading (opening) course related material as well. While this is not strictly engagement in our case it is an indicated of success as we use Moodle to host all class handouts and activities as well. Would someone be able to post me in the correct direction? Thanks!
• Wed, Apr 1, 2015, 7:57 PM
Hi, I have installed engagement analytics in moodle 2.6 (mod, block, report).
The results for assessment and login are exact, while in the forum section of the report users either have 100% risk (even if they have read posts), either 69% risk that doesn' t change no matter if some students have made many posts or if i change the settings (e.g. Min risk 0.1 (posts, read, etc), max 0). The problem (standard percentages that don't differentiate for each user) exists for all the forum indicators (posts, total posts, replies).... Thanks!
• Thu, Apr 30, 2015, 5:39 AM
good afternoon

I would like to help me with this error that I get in my moodle , moodle my version is 2.8.5

Capability "report/engagement:manage" was not found! This has to be fixed in code.
line 389 of \lib\accesslib.php: call to debugging()
line 1299 of \lib\adminlib.php: call to has_capability()
line 3639 of \lib\navigationlib.php: call to admin_externalpage->check_access()
line 3671 of \lib\navigationlib.php: call to settings_navigation->load_administration_settings()
line 3671 of \lib\navigationlib.php: call to settings_navigation->load_administration_settings()
line 3622 of \lib\navigationlib.php: call to settings_navigation->load_administration_settings()
line 3471 of \lib\navigationlib.php: call to settings_navigation->load_administration_settings()
line 719 of \lib\pagelib.php: call to settings_navigation->initialise()
line 768 of \lib\pagelib.php: call to moodle_page->magic_get_settingsnav()
line 6592 of \lib\adminlib.php: call to moodle_page->__get()
line 34 of \admin\reports.php: call to admin_externalpage_setup()
• Fri, May 1, 2015, 11:23 AM
@Jose Mesa: That's odd. Did the plugin install correctly? Can you see the capability listed in the report/engagement/db/access.php file?
• Thu, May 7, 2015, 4:49 AM
Adam Olley and install the three plugins correctly there are no errors but now my problem is how do I genererar the report, I do not get the tab Engagement analytics reporting could help me with that please Thanks .
• Fri, Jun 5, 2015, 10:38 PM
I am running Moodle 2.7 with the Engagement Analytics installed. The Login Activity is not reporting any information, although I know the students are logging in. Is there any way to get login activity added back into the analytics? Although the assessment activity is important, I really would like to know how the login activity is affecting the grades.
• Tue, Jun 23, 2015, 4:20 AM
Any chance this one will make it to the 2.8 branch?
Please login to post comments