Skip to content

Instantly share code, notes, and snippets.

@jonasrosland
Last active December 22, 2015 22:58
Show Gist options
  • Save jonasrosland/6543242 to your computer and use it in GitHub Desktop.
Save jonasrosland/6543242 to your computer and use it in GitHub Desktop.
Mystery Science Theater 3000 GraphGist for the Neo4j GraphGist challenge

Mystery Science Theater 3000 Actors and Characters - GraphGist for the Neo4j GraphGist challenge

This Graph is based on the MST3K TV-series that ran during the 1990s. Awesome TV-serie, my favourite actually. I created this Graph based on the characters of the show and where they live/reside/hunt, and which actors played them. As the Actors usually played several characters, and many characters were played by several actors, the graph get’s a bit interesting :) Enjoy!

1380475993
//Locations
CREATE (sol{name:'Satellite of Love'})
CREATE (deep13{name:'Deep 13'})
CREATE (widowmaker{name:'Widowmaker'})

//Actors
CREATE (michael{name:'Michael J. Nelson'})
CREATE (trace{name:'Trace Beaulieu'})
CREATE (kevin{name:'Kevin Murphy'})
CREATE (mary{name:'Mary Jo Pehl'})
CREATE (josh{name:'Josh Weinstein'})
CREATE (joelhodgson{name:'Joel Hodgson'})
CREATE (bill{name:'Bill Corbett'})
CREATE (jim{name:'Jim Mallon'})
CREATE (patrick{name:'Patrick Brantseg'})
CREATE (frankconniff{name:'Frank Conniff'})


//Characters

CREATE (tom{name:'Tom Servo'})
CREATE (crow{name:'Crow T. Robot'})
CREATE (mike{name:'Mike Nelson'})
CREATE (joel{name:'Joel Robinson'})
CREATE (gypsy{name:'Gypsy'})
CREATE (cambot{name:'Cambot'})
CREATE (frank{name:'TV\'s Frank'})
CREATE (forrester{name:'Dr. Clayton Forrester'})
CREATE (pearl{name:'Pearl Forrester'})
CREATE (erhardt{name:'Dr. Laurence "Larry" Erhardt'})
CREATE (bobo{name:'Professor Bobo'})
CREATE (observer{name:'Observer ("Brain Guy")'})

//Played by
CREATE (tom)-[:PLAYED_BY]->(kevin)
CREATE (tom)-[:PLAYED_BY]->(josh)
CREATE (crow)-[:PLAYED_BY]->(trace)
CREATE (crow)-[:PLAYED_BY]->(bill)
CREATE (mike)-[:PLAYED_BY]->(michael)
CREATE (joel)-[:PLAYED_BY]->(joelhodgson)
CREATE (gypsy)-[:PLAYED_BY]->(josh)
CREATE (gypsy)-[:PLAYED_BY]->(jim)
CREATE (gypsy)-[:PLAYED_BY]->(patrick)
CREATE (cambot)-[:PLAYED_BY]->(kevin)
CREATE (frank)-[:PLAYED_BY]->(frankconniff)
CREATE (forrester)-[:PLAYED_BY]->(trace)
CREATE (pearl)-[:PLAYED_BY]->(mary)
CREATE (erhardt)-[:PLAYED_BY]->(josh)
CREATE (bobo)-[:PLAYED_BY]->(kevin)
CREATE (observer)-[:PLAYED_BY]->(bill)

//Character Locations
CREATE (sol)<-[:IS_IN]-(tom)
CREATE (sol)<-[:IS_IN]-(crow)
CREATE (sol)<-[:IS_IN]-(mike)
CREATE (sol)<-[:IS_IN]-(joel)
CREATE (sol)<-[:IS_IN]-(gypsy)
CREATE (sol)<-[:IS_IN]-(cambot)
CREATE (deep13)<-[:IS_IN]-(forrester)
CREATE (deep13)<-[:IS_IN]-(frank)
CREATE (deep13)<-[:IS_IN]-(erhardt)
CREATE (widowmaker)<-[:IS_IN]-(pearl)
CREATE (widowmaker)<-[:IS_IN]-(bobo)
CREATE (widowmaker)<-[:IS_IN]-(observer)

Who lives where?

MATCH (l)<-[:IS_IN]-(c)
RETURN l.name AS Location, c.name AS Character

Who plays Crow and Tom Servo?

MATCH (c)-[:PLAYED_BY]->(a)
WHERE c.name='Tom Servo' OR c.name='Crow T. Robot'
RETURN c.name AS Character, a.name AS Actor

Who lives on the SOL?

MATCH (l)<-[:IS_IN]-(c)
WHERE l.name='Satellite of Love'
RETURN l.name AS Location, c.name AS Character

Who lives in Deep 13?

MATCH (l)<-[:IS_IN]-(c)
WHERE l.name='Deep 13'
RETURN l.name AS Location, c.name AS Character

Who rides around in the Widowmaker?

MATCH (l)<-[:IS_IN]-(c)
WHERE l.name='Widowmaker'
RETURN l.name AS Location, c.name AS Character
@cleishm
Copy link

cleishm commented Nov 4, 2013

Hi @virtualswede. This GraphGist doesn't work with the latest Neo4j 2.0 milestone. I've updated it here: https://gist.github.com/cleishm/7304234. Can you update this copy?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment