Mining Cash Flow Line

Takes QUANDL Bitcoin blockchain difficulty data, three variables (hashrate in THs /sec, power consumption in kWh, and electricity costs in cents/kWh) and calculates the base line for cash flow in US dollars. The default is an AntMiner S15 at 10 cents/kWh.

When price is above this line, miners with the given conditions have positive cash flow (i.e. they make more money mining than their running costs), and when below the line, they would be better off turning their rigs off (if this simple model can be applied to their particular circumstance).

1. All costs are consolidated into one "electricity cost" variable, including things like rent and wages for mining farms.
2. 12.5 BTC /block emission schedule (update source code upon next halving).

It is likely that actual costs to miners varies in complex ways. This indicator only shows a cash flow calculation for a very simple set of parameters that will generally apply to miners, but not necessarily all of them. (For example, a miner may be locked into a prepaid contract for cheap electricity, or sell exhaust heat in the winter for extra revenue.)
Positive cash flow is also different from ROI , as this model does not take into account the cost of acquiring an ASIC mining rig.
הערות שחרור: Updated script to make the following changes:

- Emission rate is 6.25 BTC per block to reflect the third halving (May 11 2020)
- Default electricity price is now set to $0.03 to reflect more realistic (competitive) conditions
הסר מסקריפטים מועדפים הוסף לסקריפטים מועדפים


Dude, this is amazing. Thank you fro the share. May I ask though, if I were to use the QUANDL: ticker without s premium account, would the indicator still work?

As I understood, NASDAQ bought Quandl and it wasn’t possible to get Quandl data anymore. Am I wrong? (Obviously I’m wrong)
+1 השב
kishin chrysopoetics
@chrysopoetics, I checked with a free account, QUANDL:BCHAIN/DIFF is available to free users. But you are right, some QUANDL data is premium only, but afaik their blockchain data is free. Please let me know if this isn't the case.
(Update 11/26/2019)
There is strong evidence to suggest Antminer S9 miners, the main arsenal for most miners in the past several years, are gradually being phased out. DYOR to find a good next-gen model's specs for more accurate results.
@kishin, This indicator is a staple thank you
I have updated the settings for the S19 pro with 3.3kwh and 110 th
Seems the price to mine is down in the $3k range... this has me rethinking a bull market scenario and will be interesting to study using your indicator model
For some reason the chart shows the line for 10 cents/kWh while the code is 7 cents/kWh but both are correct.
Feel free to fork & make your own improved indicator :)
@kishin, I Modified one for LTC , Data is manual entry but it gets it on the chart.
+1 השב
kishin MaX_Head_Room
@MaX_Head_Room, Awesome!
בית סורק מניות סורק מט"ח סורק מטבעות-קריפטו יומן כלכלי איך זה עובד‏ תכונות גרף מחירון הפנה חבר כללי הבית מרכז תמיכה כלים לאתרים וברוקרים יישומונים פתרונות גרפיים ספריית גרפים קלי משקל בלוג וחדשות טוויטר‏
פרופיל הגדרות פרופיל חשבון וחיוב חברים מופנים מטבעות לשוניות התמיכה שלי מרכז תמיכה רעיונות שפורסמו עוקבים עוקב הודעות פרטיות צ'אט התנתק