Useful tip from the late creator of matplotlib, John Hunter.
http://matplotlib.1069221.n5.nabble.com/dynamically-add-subplots-to-figure-td23571.html
import matplotlib.pyplot as plt
# start with one
fig = plt.figure()
ax = fig.add_subplot(111)
// copy paste this in console | |
function shader_exporter(duration, width, heigth, paused) { | |
document.getElementById('demogl').style.width = width + 'px'; | |
document.getElementById('demogl').style.height = heigth + 'px'; | |
document.getElementById('myResetButton').click(); | |
document.getElementById('myRecord').click(); | |
if (paused) document.getElementById('myPauseButton').click(); | |
let t0 = performance.now(); | |
function loop(){ | |
if (performance.now() - t0 > duration * 1000) { |
Useful tip from the late creator of matplotlib, John Hunter.
http://matplotlib.1069221.n5.nabble.com/dynamically-add-subplots-to-figure-td23571.html
import matplotlib.pyplot as plt
# start with one
fig = plt.figure()
ax = fig.add_subplot(111)
A personal diary of DataFrame munging over the years.
Convert Series datatype to numeric (will error if column has non-numeric values)
(h/t @makmanalp)
Given J*JT * x = b, solve for x in linear time and space. | |
J is m by n | |
x is m by 1 | |
b is m by 1 | |
m < n | |
J is a rectangular matrix that represents a tree with equal and opposite entries. | |
For example: |