Skip to content

Instantly share code, notes, and snippets.

View daschw's full-sized avatar

Daniel Schwabeneder daschw

  • AIT Austrian Institute of Technology
  • Vienna, Austria
View GitHub Profile
JuliaVersion tmin UsingTime PlotTime DisplayTime
1.5.0 0.01 5.448030544 3.387627208 6.380556395
1.5.0 0.01 6.402493917 3.985001957 6.444637545
1.5.0 0.01 5.071070104 3.979988927 6.354740785
1.4.2 0.01 13.060435346 7.43419821 11.374916817
1.4.2 0.01 10.226962577 5.97712717 11.688365887
1.4.2 0.01 10.212576838 6.016044048 11.526914061
1.3.1 0.01 10.956528388 21.68826932 11.056077117
1.3.1 0.01 10.924949937 23.47655248 8.401617246
1.3.1 0.01 8.312926382 16.638795094 8.315054376
@daschw
daschw / triangular_heatmap.jl
Last active July 20, 2017 21:00
triangularheatmap userplot recipe for plotting data defined on a honeycomb lattice
using Plots; backend()
# get a upper/lower triangle shape for the heatmap on an underlying honeycomb lattice
function _triangle(center::NTuple{2}, hexlength::Real, triangle_orientation::Symbol = :lower)
@assert triangle_orientation in (:upper, :lower)
sgn = triangle_orientation == :upper ? 1 : -1
Plots.Shape(
[center .+ edge for edge in
[
(0, sgn * hexlength),