-
-
Save staccDOTsol/0db4b15d70f4e4d67631a62b6d08d936 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
if math.fabs(arb) > avg: | |
percs[coinarbs[arb].split('-')[0]] = arb / t | |
if coinarbs[arb] in usdpos: #-0.3 * 10 * 100 + 360 #-0.16*400*10+1826=1186 | |
#-0.16*400*10-266=-906 | |
wanting[coinarbs[arb]] = arb / t * 7.5 * balance | |
wanting[coinarbs[arb]] = wanting[coinarbs[arb]] * -1 | |
wanting[coinarbs[arb]] = wanting[coinarbs[arb]] - usdpos[coinarbs[arb]] | |
else: | |
wanting[coinarbs[arb]] = arb / t * 7.5 * balance | |
wanting[coinarbs[arb]] = wanting[coinarbs[arb]] * -1 | |
if coinarbs[arb].split('-')[0] + '-PERP' in usdpos: | |
wanting[coinarbs[arb].split('-')[0] + '-PERP'] = percs[coinarbs[arb].split('-')[0]] * 7.5 * balance - usdpos[coinarbs[arb].split('-')[0] + '-PERP'] | |
else: | |
wanting[coinarbs[arb].split('-')[0] + '-PERP'] = percs[coinarbs[arb].split('-')[0]] * 7.5 * balance |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment