Skip to content

Instantly share code, notes, and snippets.

timelyportfolio timelyportfolio

Block or report user

Report or block timelyportfolio

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@jcheng5
jcheng5 / addDynamicTiles.R
Created Jan 19, 2019
Leaflet dynamic tiles
View addDynamicTiles.R
library(shiny)
library(leaflet)
#' Add a tile layer whose source is an R function
#'
#' @param tileFunc A function(x, y, z) that returns a 256x256 image object
#' suitable for passing to `png::writePNG`.
#' @seealso [leaflet::addTiles()] for other parameters
addDynamicTiles <- function(map, tileFunc,
layerId = paste0("leafletRaster", sample.int(9999999, 1)),
@domoritz
domoritz / .block
Last active Sep 27, 2018
Vega-Lite with Websockets
View .block
license: bsd-3-clause
@bumbeishvili
bumbeishvili / .block
Last active May 22, 2019
Employees Hierarchy Chart using d3.js
View .block
license: mit
@stephlocke
stephlocke / LockeTree.css
Last active Jan 5, 2018
Working Site Tree
View LockeTree.css
.collapsibleTree .node circle {
fill: #E8830C;
stroke: #E8830C;
}
.collapsibleTree .node text {
fill: white;
}
.collapsibleTree .link {
@veltman
veltman / README.md
Created Dec 27, 2017
Automatic label placement along a path #2
View README.md

A method for automatically finding the best eligible label position and font size for a label that's going to go along a path inside of an area, similar to this example but with two embellishments:

  • Using d3plus.polygonRayCast() to more accurately measure the vertical clearance available at a given x position with any rotation.
  • Avoiding label positions that would cause the text to be overlapped by another shape for a case like this bump chart.

The measurement gets thrown off a little bit by the curve function and the fact that text is rotated letter by letter instead of continuously, but the results seem good enough.

See also: Automatic label placement along a path Streamgraph label positions #2

@EE2dev
EE2dev / index.html
Last active Dec 21, 2017
Sequence explorer - single chart (with JSON file)
View index.html
<!DOCTYPE html>
<meta charset="utf-8"> <!-- also save this file as unicode-8 ! -->
<head>
<link rel="stylesheet" type="text/css" href="https://ee2dev.github.io/libs/sankeySeqExplorer.v20.css">
<script src="https://d3js.org/d3.v4.min.js"></script>
<script src="https://ee2dev.github.io/libs/sequence-explorer.v20.min.js"></script>
</head>
<body>
<script>
@romsson
romsson / .block
Last active Dec 21, 2017
vertical horizontal nesting (grids)
View .block
license: mit
@Kcnarf
Kcnarf / .block
Last active Aug 17, 2018
d3-voronoi-map usage
View .block
license: mit
View .ne_110m_admin_0_countries.json
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
You can’t perform that action at this time.