This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://www.statology.org/matplotlib-python-candlestick-chart/ | |
import matplotlib.pyplot as plt | |
#create figure | |
plt.figure() | |
#define width of candlestick elements | |
width = .4 | |
width2 = .05 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class IntrinsicTimeBar: | |
reversal: False | |
direction: None | |
time: None | |
high: None | |
low: None | |
def __init__(self, time, high: float, low: float, direction=None, reversal=False): | |
self.reversal = reversal | |
self.direction = direction |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import yfinance as yf | |
import pandas as pd | |
import numpy as np | |
import pandas_datareader as pdr | |
import matplotlib.pyplot as plt | |
import plotly | |
import plotly.graph_objects as go | |
yf.pdr_override() | |
stock = yf.Ticker("SPY") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { sha256 } from "sha.js"; | |
type Data = { | |
[k: string]: { | |
[k: string]: string | number | boolean, | |
} | |
}; | |
const data: Data = {}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import omit from "lodash.omit"; | |
import keys from "lodash.keys"; | |
export default (ref1) => { | |
if (typeof ref1 !== "object") return ref1; | |
function stripProp(prop, ref2) { | |
if (typeof ref2[prop] !== "object") return; | |
/* eslint-disable-next-line no-param-reassign */ | |
ref2[prop] = omit(ref2[prop], "_"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const add = (a, b) => a + b; | |
export const subtract = (a, b) => a - b; | |
export default { add, subtract }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function predicatesToList(thingId) { | |
var thing = g.V(thingId); | |
var result = []; | |
thing.outPredicates().map(function(a){ | |
if (!a) return; | |
thing.out(a.id).map(function(b){ | |
result.push([a.id, b.id]); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/******************************\ | |
The Thunk Emperor Has No Clothes | |
\******************************/ | |
/* ACT ONE | |
myAction: | |
"I'm an action creator!" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
################### | |
## SAMPLE OUTPUT ## | |
################### | |
: <<'END' | |
Press Ctrl-C to exit at any point | |
Please enter a name for this cluster: prod1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Installs the ArangoDB Operator into a Kubernetes cluster | |
LOCAL_STORAGE_YAML="\ | |
apiVersion: storage.arangodb.com/v1alpha | |
kind: ArangoLocalStorage | |
metadata: | |
name: example-arangodb-storage | |
spec: | |
storageClass: |
NewerOlder