Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This was used in 2016 and June 2020 for tracking / visualization. (data linked)

XBlock counts
Code Block
MATCH
    (c:course) -[:PARENT_OF*]-> (n:item)
RETURN
    distinct(n.block_type) as block_type,
    count(distinct(c)) as coursecount,
    count(n) as number
order by
    number DESC

...

Code Block
MATCH 
	(c:course)-[:PARENT_OF*]->(n:`block_name`)
WHERE 	
	(n.field_name)
RETURN 
	c.org, 
	c.course_key
ORDER BY 
	c.org, 
	c.course_key

Where are all the

...

XBlock types used in my course? (with direct link to where they are used)

Code Block
MATCH
    (c:course) -[:PARENT_OF*]-> (v:vertical) -[:PARENT_OF*]-> (n:item)
WHERE
    c.course_key = 'courseID' // replace with the course ID
    AND
    n.block_type = 'problem' // insert desired block type here
RETURN  
    n.block_type,
    n.display_name,
    n.location as block_id,
    v.display_name as unit_location,
    replace('https://courses.edx.org/courses/course-id/jump_to_id/','course-id',c.course_key) + right(n.location, 32) as Unit_URL,
    n.edited_on, 
    n.visible_to_staff_only
ORDER BY
  n.edited_on;

...

Code Block
MATCH 
	(course)-[:PARENT_OF*]->(p:problem) 
WHERE 
	p.data 
CONTAINS 
	'jsinput' 
RETURN 
	distinct(p.org) as org, 
	count(distinct(p.course_key)) as numberOfCourses, 
	count(distinct(p)) as numberOfProblems

Courses with new drag and drop

...

XBlocks

new drag and drop problems by course

...

Code Block
MATCH
    (n:chapter)
RETURN
    max(length(n.display_name))

How many pages contain nested

...

XBlocks

Find and count the xblocks XBlocks (p) that contain other xblocks XBlocks ( n), that appear in units (v). For all these searches, you'll get more real results by adding  constraints like "vertical in a recent course" or "is published to learners" 

Nested

...

XBlocks in Units
Code Block
MATCH
    (v:vertical) -[:PARENT_OF]-> (p) -[:PARENT_OF*]-> (n)
RETURN
    distinct(p.block_type), count(p)

Note for the below that we're not eliminating cyclical relationships; no guarantee that n is a leaf node.

Units with Nested

...

XBlocks
Code Block
//Count all units that contain nested xblocks i.e. blocks that contain other blocks
MATCH (v:vertical) -[:PARENT_OF]-> (p) -[:PARENT_OF*]-> (n) return count(distinct(v))

...

Code Block
match (c:course) 
where c.discussion_blackouts <> [] // non null blackout dates
return c.org, c.course_key, c.display_name, c.start, c.end, c.discussion_blackouts

Discussion forums

What courses don't use

...

the built-in

...

discussion forums?

Code Block
MATCH (c:course) WHERE LENGTH([x IN c.tabs WHERE x CONTAINS "DiscussionTab"]) = 0 RETURN c.course_key

...