greed
Greed is a tool for automating trades 📈
| Note: Use at your own risk! This tool is in active development and may have bugs! |
|---|
Investment Platforms
Currently, Greed supports the following investment platforms:
Credentials
Alpaca
To use Alpaca add the following variables to your environment:
export APCA_API_KEY_ID='<live_key_id>'
export APCA_API_SECRET_KEY='<live_secret_key>'
# The below can be used for paper trading. Invoke greed with -s to use paper trading.
export SIMULATED_APCA_API_KEY_ID='<paper_key_id>'
export SIMULATED_APCA_API_SECRET_KEY='<paper_secret_key>'
Running Greed 🚀
To run Greed in a simulated environment, you can use the following command:
To run Greed in a live environment, you can use the following command:
Configuration
# The interval between each strategy run in seconds
= 300
# The platform to use for trading (alpaca)
= "alpaca"
[[]]
# Each strategy can have an optional name
= "ETF"
# Each stategy has for, when and do rules.
# In the following example we are buying $VTI when it is below the median price by 5% and selling when the gain is above 5%
[]
= { = "$VTI" }
= { = 5.0 }
= { = 10 }
# You can have as many strategies as you'd like in a single configuration.
[]
= { = "$VTI" }
= { = 5.0 }
= { = true }
[[]]
= "Chaos"
[]
= { = "$UVXY" }
= { = 2.0, = "week" }
= { = 5 }
[]
= { = "$UVXY" }
= { = 3.0 }
= { = true }