A python package to interact with the tradingbot22 backend. used in tradingbot22-tradingbots
Project description
Published on: https://pypi.org/project/basebot22-basebot-JustinGuese/
tradingbot22-basebot
python package to interact with the tradingbot22-backend, used in tradingbot22-tradingbots
pip install basebot22-basebot-JustinGuese
or
pip install -U git+https://github.com/JustinGuese/tradingbot22-basebot/
Import with
from basebot22.basebot import BaseBot
usage
bot = BaseBot("testbot")
print(bot.getPortfolio())
bot.buy("AAPL", 2000, amountInUSD=True)
print("portfolio after buy")
print(bot.getPortfolio())
print("portfolio after sell")
bot.sell("AAPL", 1500, amountInUSD=True)
print(bot.getPortfolio())
print("portfolio worth is: %.2f dollars" % bot.getPortfolioWorth())
print("next earnings calendar events:")
print(bot.getEarnings(only_now=True))
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for basebot22-basebot_JustinGuese-0.3.23.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 94f8f355842e04165e78217fe1b9779e7bf83d914770e337b0b1ba8d45edc5d1 |
|
MD5 | 83ecbf6041c01f5eadafbf714b337342 |
|
BLAKE2b-256 | 2a8ba3ec3b0d65a7ec5b9b9d7c844336a6031114603519fdb12f5f1cc685402e |
Close
Hashes for basebot22_basebot_JustinGuese-0.3.23-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e4b71afdad597352adb2b45ed11e1756b3242f9b1a2d32fc458d274ae462dada |
|
MD5 | b91d7f21c8f53f3b1cd31c459dc71132 |
|
BLAKE2b-256 | 224d4647948266a293fd0fd9168e951c623e26c7f1c3312ca95d2b59dcf0b5f4 |