Skip to content

Instantly share code, notes, and snippets.

View iCodeForBananas's full-sized avatar

Michael Calkins iCodeForBananas

  • AWS
  • Seattle, WA
View GitHub Profile
//@version=5
strategy("MA Price Cross w/ Continuous Entries Strategy", overlay=true, initial_capital = 5000, default_qty_value = 1, pyramiding = 0)
hmaLength = input(20, 'Trigger MA length (default HMA)', group = 'Trade entry')
smaEnabled = input.bool(false, "Use SMA", group = 'Trade entry')
emaEnabled = input.bool(false, "Use EMA", group = 'Trade entry')
ma = ta.hma(close, hmaLength)
closeTradesEOD = input.bool(false, 'Close trades end of day', group = 'Other settings')
@iCodeForBananas
iCodeForBananas / horizontallines.pine
Created December 17, 2022 18:15
horizontal lines on trading view
//@version=5
indicator("Horizontal Lines", overlay=true)
lineColor = input(title="Line color", defval = color.new(color.blue, 50))
selectedprice = input.float(title="Starting price", defval=4000)
lineInterval = input(title="Line interval", defval=5)
for i = 0 to 25
line.new(bar_index, selectedprice+(lineInterval*i), bar_index-1, selectedprice+(lineInterval*i), extend=extend.both, color=lineColor, style=line.style_solid, width=1)
line.new(bar_index, selectedprice-(lineInterval*i), bar_index-1, selectedprice-(lineInterval*i), extend=extend.both, color=lineColor, style=line.style_solid, width=1)
@iCodeForBananas
iCodeForBananas / PracticeTrading.js
Last active March 14, 2025 09:55
Lets you trade off of replay mode so that you can keep track of practice sessions. Use one pane to trade from, and keep your mouse off the chart because I have to grab the close price from the HTML that's related to where the mouse hovers..
// ==UserScript==
// @name Practice Trading
// @version 12
// @description Lets you trade off of replay mode so that you can keep track of practice sessions.
// @author iCodeForBananas
// @match https://www.tradingview.com/chart/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=tradingview.com
// @grant none
// ==/UserScript==
//@version=5
indicator("VWAP Std Dev Position", shorttitle="VWAP Expansion")
devUp1 = input(1.28, title="Stdev above (1)")
devDn1 = input(1.28, title="Stdev below (1)")
devUp2 = input(2.01, title="Stdev above (2)")
devDn2 = input(2.01, title="Stdev below (2)")
devUp3 = input(2.51, title="Stdev above (3)")
//@version=5
indicator("VWAP Relative Strength", shorttitle="Relative VWAP Expansion")
devUp1 = input(1.28, title="Stdev above (1)")
devDn1 = input(1.28, title="Stdev below (1)")
devUp2 = input(2.01, title="Stdev above (2)")
devDn2 = input(2.01, title="Stdev below (2)")
devUp3 = input(2.51, title="Stdev above (3)")
//@version=5
indicator("Relative VWAP Std Dev Oscillator")
devUp1 = input(1.28, title="Stdev above (1)")
devDn1 = input(1.28, title="Stdev below (1)")
devUp2 = input(2.01, title="Stdev above (2)")
devDn2 = input(2.01, title="Stdev below (2)")
devUp3 = input(2.51, title="Stdev above (3)")
@iCodeForBananas
iCodeForBananas / index.js
Last active January 1, 2022 19:07
Focus Mode OneOption Chat Room
// ==UserScript==
// @name Focus Mode OneOption Chat Room
// @version 0.1
// @description Maxmimizes the chat and hides all other functionality except for likes.
// @match https://oneoption.com/chat-room*
// @icon https://oneoption.com/Content/images/favicon-180.png
// ==/UserScript==
(function () {
"use strict";
//@version=5
// Based off of Oliver Velez's concept of moving averages being zones
// or magnets that pull and bend price. Like leaning into a fence.
indicator(title="Moving Average Zone", shorttitle="MA Zone", overlay=true, timeframe="", timeframe_gaps=true)
ma_len = input.int(20, minval=1, title="Moving average length")
center_line_width = input(1, title="Center line width")
center_line_color = input.color(color.new(color.blue, 50), "Center line color")
@iCodeForBananas
iCodeForBananas / cloudSettings
Last active April 2, 2020 21:21
VisualStudioCodeSync
{"lastUpload":"2020-04-02T21:21:43.487Z","extensionVersion":"v3.4.3"}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, shrink-to-fit=no"
/>
<meta name="theme-color" content="#000000" />
<!--