Skip to content

Instantly share code, notes, and snippets.

View peterneubauer's full-sized avatar

Peter Neubauer peterneubauer

View GitHub Profile

US Flights & Airports: Delays, Cancellations, & Diversions


@peterneubauer
peterneubauer / mono.rb
Last active August 29, 2015 13:57 — forked from shtirlic/mono.rb
# http://www.mono-project.com/Compiling_Mono_on_OSX
require 'formula'
class Mono < Formula
url 'http://download.mono-project.com/sources/mono/mono-3.2.8.tar.bz2'
sha1 'e2187f80366fcd65c55a1ab946f8d3b39e81be77'
#url 'http://download.mono-project.com/sources/mono/mono-2.10.9.tar.bz2'
#sha1 '1a6e8c5a0c3d88d87982259aa04402e028a283de'
# http://www.mono-project.com/Compiling_Mono_on_OSX
require 'formula'
class Mono < Formula
#url 'http://download.mono-project.com/sources/mono/mono-3.0.6.tar.bz2'
#sha1 'e2187f80366fcd65c55a1ab946f8d3b39e81be77'
url 'http://download.mono-project.com/sources/mono/mono-2.10.9.tar.bz2'
sha1 '1a6e8c5a0c3d88d87982259aa04402e028a283de'

Movie recommendation based on User preferences and Actor weights

Given a movie database, with a structure like

(actor:Actor)-[:ACTS_IN { percent: y }]→(film:Movie) so that the system knows how long each actor is physically present on the screen, and to what % of the movie duration that corresponds.

Each user can have preferences for some actors (ie: grade them from "bad" to "awesome" or whatnot). To each of this preference the system is associated to a modifier (say from -100 to +100).

== Welcome! Create and share your own online graph here.
:neo4j-version: 2.0.0
:author: Peter Neubauer
:twitter: @neterneubauer
:tags: domain:example
Neo4j Graph Gists are a way to share documents including Cypher queries. Without installing any local software, you can prototype your idea with full database functionality here, in your browser. Consider the following:
@peterneubauer
peterneubauer / events
Created July 15, 2014 14:14
OSCON CSV export
"serial","name","time_start","time_end","venue_serial","speakers"
"33451","Migrating to the Web Using Dart and Polymer - A Guide for Legacy OOP Developers","2014-07-23 17:00:00","2014-07-23 17:40:00","1458","149868"
"33457","Refactoring 101","2014-07-23 11:30:00","2014-07-23 12:10:00","1458","169862"
"33463","Open Source and Mobile Development: Where Does it go From Here?","2014-07-23 10:40:00","2014-07-23 11:20:00","1449","169870,2216,96208,150073"
"33464","Open Source Protocols and Architectures to Fix the Internet of Things","2014-07-23 16:10:00","2014-07-23 16:50:00","1451","2216"
"33476","Scaling PHP in the Real World!","2014-07-23 14:30:00","2014-07-23 15:10:00","1458","54107"
"33481","API Ecosystem with Scala, Scalatra, and Swagger at Netflix","2014-07-23 17:00:00","2014-07-23 17:40:00","1456","113667"
"33485","XSS and SQL Injections: The Tip of the Web Security Iceberg ","2014-07-23 16:10:00","2014-07-23 16:50:00","1458","169932"
"33503","Scalable Analytics with R, Hadoop and RHadoop","2014-07-23 14:3

The OSCON Graph-in-a-Gist

At Neo4j, we love going to

oscon2014 logo

This year, there is a DYI Schedule page that we are very intrigued by, so let’s build a — graph of the conference!

The Model

= Artist test
== First paragraph
[source,cypher]
----
create
(a1:Artist{name:'Awesome1'}),
(a2:Artist{name:'Awesome2'}),
W/RestTemplate(10972): GET request for "https://api.ica.se/api/user/shoppinglists/1351586" resulted in 500 (Internal Server Error); invoking error handler
E/MP-Decision( 2006): num online cores: 2 reqd : 3 available : 4 rq_depth:3.000000 hotplug_avg_load_dw: 200
E/MP-Decision( 2006): UP cpu:1 core_idx:1 Nw:1.900000 Tw:140 rq:3.000000 seq:0.000000
E/MP-Decision( 2006): UP cpu:2 core_idx:2 Nw:2.700000 Tw:90 rq:3.000000 seq:98.000000
I/dalvikvm(10972): threadid=27: stack overflow on call to Ljava/lang/String;.<init>:VLIIL
I/dalvikvm(10972): method requires 136+20+20=176 bytes, fp is 0x73af93a0 (160 left)
I/dalvikvm(10972): expanding stack end (0x73af9300 to 0x73af9000)
I/dalvikvm(10972): Shrank stack (to 0x73af9300, curFrame is 0x73af99e4)
W/dalvikvm(10972): threadid=27: thread exiting with uncaught exception (group=0x41859da0)
D/HockeyApp(10972): Writing unhandled exception to: /data/data/se.ica.handla/files/81b0636e-3eb3-48a4-a6fb-ed116e9e4b09.stacktrace
#öffne einen neuen Neo4j Graph als den default-Graphen ($_g)
$_g := neo4j:open('tmp/matrix')
#die Knoten mit Namen
$neo := g:add-v()
$neo/name := 'Neo'
$morpheus := g:add-v()
$morpheus/name := 'Morpheus'
$trinity := g:add-v()
$trinity/name := 'Trinity'