Skip to content

Instantly share code, notes, and snippets.

@harmishhk
Created August 10, 2015 15:52
Show Gist options
  • Save harmishhk/4c4937115db1fe524bef to your computer and use it in GitHub Desktop.
Save harmishhk/4c4937115db1fe524bef to your computer and use it in GitHub Desktop.
using Gadfly
points = [100 112; 500 23.25; 1000 12.05; 2000 6.5; 3000 4.65; 4000 3.8; 5000 3.2; 6000 2.8; 7000 2.55; 8000 2.35; 9000 2.2; 10000 2.1; 11000 2.0; 12000 1.9]
p = plot(x=points[:,1], y=points[:,2], Geom.point)
velocities = [100 0.044642857; 500 0.215053763; 1000 0.414937759; 2000 0.769230769; 3000 1.075268817; 4000 1.315789474; 5000 1.5625; 6000 1.785714286; 7000 1.960784314; 8000 2.127659574; 9000 2.272727273; 12000 2.631578947]
pv = plot(x=velocities[:,1], y=velocities[:,2], Geom.point)
draw(SVGJS("result.svg", 30cm, 30cm), vstack([p, pv]))
Display the source blob
Display the rendered blob
Raw
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment