Skip to content

Instantly share code, notes, and snippets.

View mdsumner's full-sized avatar

Michael Sumner mdsumner

  • Integrated Digital East Antarctica, Australian Antarctic Division
  • Hobart, Australia
View GitHub Profile
@timelyportfolio
timelyportfolio / Readme.md
Created January 25, 2017 20:52
igraph layout editing with mapedit

This is certainly not the intended purpose of mapedit, but I thought it would be fun to use some accumulated R knowledge to use mapedit and leaflet to edit an igraph layout. To run the code, make sure to run the edit_map and Shiny parts separately.

library(igraph)
library(leaflet)
library(mapedit)

karate <- graph.famous("Zachary")
igrf_layout <- layout.auto(karate)
@jeroen
jeroen / shit.md
Last active March 4, 2022 07:18
Getting shit to work

Getting shit to work

Disclaimers

  • No authority
  • Official reference is writing r extentions (joke extentions)
  • If you thought writing regular r packages was tricky, hold on
#include <iostream>
#include <boost/shared_ptr.hpp>
#include <gdal/ogrsf_frmts.h>
#include <geos_c.h>
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
#include <CGAL/Polygon_with_holes_2.h>
#include <CGAL/create_straight_skeleton_from_polygon_with_holes_2.h>
typedef CGAL::Exact_predicates_inexact_constructions_kernel K ;