Vindruee

Statistical approach to risk management - Python script

教育
Vindruee アップデート済   
CBOE:VIN   CBOE Near-term VIX Index
This script can be used to approximate a strategy, and find optimal leverage.
The output will consist of two columns, one for the median account size at end of trading, and one for the share of accounts liquidated.

The script assumes a 100% position size for the account.
This does not take into account size deviations for earnings and losses, so use with a grain of salt if your positions vary greatly in that aspect.

Code preview
cdn.discordapp.com/attachments/592684708551327764/848701541766529034/carbon.png
TradingView does not allow posting external links until you've reached a specific reputation, so i can't use the url feature

Input explanation
  • WINRATE : chance of winning trade
  • AVGWIN : average earning per winning trade
  • AVGLOSS : average loss per losing trade

  • MAX_LEVERAGE : maximum leverage available to you

  • TRADES : how many trades per account you want to simulate
  • ACCOUNTS : how many accounts you want to simulate

    the inputs used in the source code are from one of my older strategies, change them to suit your algorithm

Source code
pastebin.com/69EKdVFC

Good luck, Have fun
-Vin
トレード稼働中:
Left a mistake in the code, here's an updated version:

Preview:
cdn.discordapp.com/attachments/592684708551327764/849339593798582312/carbon.png

Source code:
pastebin.com/0Vst4uJW
免責事項

これらの情報および投稿は、TradingViewが提供または保証する金融、投資、取引、またはその他の種類のアドバイスや推奨を意図したものではなく、またそのようなものでもありません。詳しくは利用規約をご覧ください。