Created by Christopher Manning
This is an experiment using a random walk to draw shapes. Adjusting theta results in a very organic or procedural drawing. The random walk stays in the geometry by using a point in polygon test.
Controls
{"nodes":[{"name":"a"},{"name":"b"},{"name":"c"},{"name":"d"},{"name":"e"},{"name":"f"},{"name":"g"},{"name":"h"},{"name":"i"},{"name":"j"},{"name":"k"},{"name":"l"},{"name":"m"},{"name":"n"},{"name":"o"},{"name":"p"},{"name":"q"},{"name":"r"},{"name":"s"},{"name":"t"},{"name":"u"},{"name":"v"},{"name":"w"},{"name":"x"},{"name":"y"},{"name":"z"},{"name":"aa"},{"name":"ab"},{"name":"ac"},{"name":"ad"},{"name":"ae"},{"name":"af"},{"name":"ag"},{"name":"ah"},{"name":"ai"},{"name":"aj"},{"name":"ak"},{"name":"al"},{"name":"am"},{"name":"an"},{"name":"ao"},{"name":"ap"},{"name":"aq"},{"name":"ar"},{"name":"as"},{"name":"at"},{"name":"au"},{"name":"av"},{"name":"aw"},{"name":"ax"}],"links":[{"source":1,"target":2,"value":74},{"source":2,"target":3,"value":64},{"source":2,"target":4,"value":46},{"source":4,"target":5,"value":45},{"source":5,"target":6,"value":45},{"source":7,"target":8,"value":45},{"source":8,"target":9,"value":65},{"source":10,"target":11,"value":42},{"source":12,"target":13,"value":20},{"source":1 |
Created by Christopher Manning
This is an experiment using a random walk to draw shapes. Adjusting theta results in a very organic or procedural drawing. The random walk stays in the geometry by using a point in polygon test.
Controls
This chart shows the path of the Sun in the sky today based on your current location. The red dot represents the current apparent position of the Sun in terms of azimuth and elevation.
The outer black circle represents the horizon, where the elevation of the Sun is 0°. If the Sun is outside this circle, it is below the horizon. (This means it’s dark outside, though note that some definitions of twilight extend as far as 18° below the horizon.) Where the path intersects the horizon determines sunrise and sunset. The inner concentric circles represent higher solar elevations.
The radiating lines of the graticule represent azimuth. For example, 0° azimuth means that the Sun is due North of your current location. The azimuth tells you the direction of shadows cast by the Sun, while the elevation determines their length.
@jalapic did these really nice set of touch heatmap charts. On Twitter, there was a discussion how to do this interactively with d3.js or some other JavaScript. I definitely have some ideas how to accomplish this, but for now let's see how we can kind of do it in rbokeh
. There is just a small issue with palette selection in Bokeh that does not let us allow a no color that prevents us from getting really close.
## https://gist.github.com/jalapic/3616c0197ece24060e99
library(rbokeh)
library(dplyr)
gana <- read.csv("https://gist.githubusercontent.com/jalapic/3616c0197ece24060e99/raw/2bc2361c5fceb9be80dece9b7ffa14d129a3edfb/gana.csv")
figure() %>%
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"> | |
<title>Treemap - Neat Zoom Effect</title> | |
<script type="text/javascript" src="http://www.billdwhite.com/wordpress/wp-content/js/browserdetect/browserdetect.js"></script> | |
<script type="text/javascript" src="http://www.billdwhite.com/wordpress/wp-content/js/d3/d3.js"></script> | |
<style type="text/css"> | |
body { | |
overflow: hidden; |
Forked this gist that contained Andrie de Vrie' code from Creating network graphs using javascript directly from R. I thought it would be a good opportunity to explore some other network visualization htmlwidgets
.
All the code is within this Gist for maximum reporducibility.
library("igraph") | |
library("plyr") | |
library("HiveR") | |
library("RColorBrewer") | |
############################################################################################ | |
rm(list = ls()) | |
dataSet <- read.table("./inst/lesmis.txt", header = FALSE, sep = "\t") | |
############################################################################################ |
This program renders a network diagram for a ModelJS reactive flow.
The input data is generated by an experimental ModelJS branch that computes the reactive flow graph at runtime.
Based on a previous implementation from July 2014
notional2005result.csv | |
notional2005result.json |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>D3 Ternary Plot</title> | |
<style> | |
a{ | |
font-family: sans-serif; | |
color: #DB7365; | |
padding: 0.3rem; |