Skip to content

Instantly share code, notes, and snippets.

@LordGhostX
Created November 29, 2022 18:06
Show Gist options
  • Save LordGhostX/9fd6f9e5ff84f33e570036c7fc32b1d7 to your computer and use it in GitHub Desktop.
Save LordGhostX/9fd6f9e5ff84f33e570036c7fc32b1d7 to your computer and use it in GitHub Desktop.
import matplotlib.pyplot as plt
def spot_formula(x, y=100):
return (1 + (x / 100)) * y
def usdt_m_formula(x, y=100):
return (1 + (x / 50)) * y
def coin_m_formula(x, y=100):
return ((1 + (x / 100)) ** 2) * y
if __name__ == "__main__":
spot = [spot_formula(x) for x in range(1, 301, 25)]
coin_m = [coin_m_formula(x) for x in range(1, 301, 25)]
usdt_m = [usdt_m_formula(x) for x in range(1, 301, 25)]
plt.plot(spot, label="spot")
plt.plot(coin_m, label="coin_m")
plt.plot(usdt_m, label="usdt_m")
plt.legend(loc="upper center")
plt.title("Sample plot on 1% to 300%")
plt.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment