Skip to content

Instantly share code, notes, and snippets.

View patryknextdoor's full-sized avatar
🤓

pnextdoor patryknextdoor

🤓
View GitHub Profile

Python & AI for Algorithmic Trading Bootcamp

3-Day Online Bootcamp about Python & AI for Algorithmic Trading

Dr. Yves J. Hilpisch

Director CPF Program | CEO The Python Quants

Online, November 13-15, 2024

@patryknextdoor
patryknextdoor / list.md
Created October 14, 2024 09:58 — forked from ih2502mk/list.md
Quantopian Lectures Saved
@patryknextdoor
patryknextdoor / options.adoc
Created May 17, 2023 13:10 — forked from johnymontana/options.adoc
My entry for the Neo4j GraphGist December competition. Very simplified options trading in a graph.

Options Trading As A Graph


Introduction

This GraphGist will begin to explore how stock option data can be modeled as a graph, some simple Cypher queries for calculating payout at expiration for an options contract and a very basic look at finding profitable options trades given a specific forecast. Please note that some of the concepts here have been simplified and are only meant as an educational overview of exploring Neo4j and graph data modeling.

@patryknextdoor
patryknextdoor / fuzzytargs.py
Created August 18, 2022 18:45 — forked from 3catz/fuzzytargs.py
Fuzzy Targets
D = reconstruct(s, dim = 22 * 2 + 5, tau = 1)
Xs = []
Ys = []
for choice in np.repeat("random",3):
X = D[:,:22 * 2] ; Y = D[:,-5:]
if choice == 'random':
import random
y = []
for i in range(len(Y)):
# expects a numpy array with trades
# each trade is composed of: [time, price, quantity]
def generate_tickbars(ticks, frequency=1000):
times = ticks[:,0]
prices = ticks[:,1]
volumes = ticks[:,2]
res = np.zeros(shape=(len(range(frequency, len(prices), frequency)), 6))
it = 0
for i in range(frequency, len(prices), frequency):
res[it][0] = times[i-1] # time