This is the Gist the For Python Quants Bootcamp in London 23. November 2017 (http://fpq.io)
This third boocamp day is about Python for Algorithmic Trading (I).
Topics
# Run with: | |
# python imagecrack.py http://staffwww.dcs.shef.ac.uk/people/R.Clayton/UoSsecret.png | |
import Image | |
from numpy import asarray | |
from urllib2 import urlopen | |
from cStringIO import StringIO | |
from sys import argv | |
png = asarray(Image.open(StringIO(urlopen(argv[1]).read()))) # open the image from URL as an array | |
print ''.join([chr(png[x,y]) for (x,y) in png[:,0:2]-1]) # for each leading pair in the array find the corresponding character (-1 from its value MATLAB 1 indexing...) |
This is the Gist the For Python Quants Bootcamp in London 23. November 2017 (http://fpq.io)
This third boocamp day is about Python for Algorithmic Trading (I).
Topics
This is the Gist the For Python Quants Bootcamp in London, 21.-24. November 2017 (http://fpq.io)
This is the Gist the For Python Quants Bootcamp in London 24. November 2017 (http://fpq.io)
This fourth boocamp day is about Python for Algorithmic Trading (II).
Topics
import SwiftUI | |
struct ContentView: View { | |
// stores the input from the text field | |
@State private var message = "" | |
// stores the saved input | |
// note the this variable is initialized from the UserDefaults | |
@State private var pesistedMessage = UserDefaults.standard.string(forKey: "UserMessage") | |
var body: some View { |