Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Crypto Analysis #56

Open
driscoll42 opened this issue Mar 12, 2021 · 4 comments
Open

Add Crypto Analysis #56

driscoll42 opened this issue Mar 12, 2021 · 4 comments
Assignees
Labels
enhancement New feature or request

Comments

@driscoll42
Copy link
Owner

Describe the solution you'd like
There's a relationship between the GPU pricing and Cryptocurrency. It would be interesting to explore this further.

@driscoll42 driscoll42 added the enhancement New feature or request label Mar 12, 2021
@driscoll42 driscoll42 self-assigned this Mar 12, 2021
@driscoll42 driscoll42 added this to Misc in ebayMarketAnalyzer via automation Mar 12, 2021
@driscoll42 driscoll42 moved this from Misc to Data Analytics in ebayMarketAnalyzer Mar 12, 2021
@driscoll42 driscoll42 moved this from Data Analytics to In progress in ebayMarketAnalyzer Mar 13, 2021
@driscoll42
Copy link
Owner Author

From discussions on Discords:

  1. Price / Hashrate over time
    The hashrate is just however many hashes you can compute per unit time (for a given graphics card), and is independent of ETH price. You'd need to look at people's posted benchmark results in forums or elsewhere.
    I mean, look at the “price paid / hashrate” ratio on the vertical axis, versus time on the horizontal. Replacing MSRP (or 2021-01-01 price) by hashrate. You'd still have exactly the same number of points as your posted plots.
    You could then further combine the data for the different models and just look at the normalised “price paid / hashrate”. Admittedly this is a dodgy approach as this normalisation ignores many other factors (e.g. cost of setting up the rest of the hardware). But it'd squash the variables for different models into just one, and get you more datapoints. Dunno if that'd help.
    It'd be nice if you could come up with a better formula for the payback time (or profitability in general), because they're completely ignoring set-up (constant) & running costs (electricity; assume linear with time I guess?).
    Or answer niche questions such as “if I underclocked my card, how might that affect my profitability?” I hypothesise there'd be a small improvement for mild underclocking due to lower electricity usage.

R^2 needs a model to give scores
VAR model
If you are doing pure predictive analysis (the goal is to forecast 2-3 days forward), VAR might be suitable

"ETH price is x% correlated with GPU price"
https://en.wikipedia.org/wiki/Granger_causality

Then you should include that into the analysis (all data going back from launch)
And if you want to use R^2, you need to fit an actual model.
R^2 is for residuals
so you have two model y=f(x) and y=g(x)
their residuals are r1 = y - f(x) and r2 = y - g(x)
and the test just compares them - rSquared = 1 - sum(r12) / sum(r22)
where r1**2 is applied element-wise
so you would fit, as an example, changeInPriceOfGpus = a * changeInPriceOfETH + b
that's one model
and another one is just changeInPriceOfGpus = c
where a, b, c are adjustable parameters
and then you can use R^2 to compare the former to the latter

plot the difference in prices
so take p(t + Δt) / p(t) for both time series
and plot one on X axis and one on Y
but I want you to plot Y = ln(pGPU(t + Δt) / pGPU(t)) against X = ln(pETH(t + Δt) / pETH(t))

So, the closer to a y=x line, would mean that a change in one implies the change in the other?
Or rather they're correlated
Big Bux Chungus — Today at 5:47 PM
Yes, in a way.
Not necessarily y=x
y=a*x+b

mining profitability depends on the price, your hashrate, and the network hashrate as
price * your_hash_rate / total_network_hash_rate * block_payment / blocks_per_second * time_in_seconds
block_payment, blocks_per_second don't depend on time
total_network_hash_rate changes over time https://www.coinwarz.com/mining/ethereum/hashrate-chart
Ethereum Hashrate Chart
that plot is just an estimate, so you might as well just draw a straight line

or at least aggregate over a sufficiently large window
a better GPU results in a better hashrate
you also pay for electricity, so you pay

  • electricity_price * gpu_power * time_in_seconds
    obviously electricity prices are different all across the globe
    but gpu_power depends on the GPU (plus some hardware settings)
    those two factors determine how much you can make

@driscoll42
Copy link
Owner Author

https://otexts.com/fpp3/

@driscoll42
Copy link
Owner Author

Suggestion from OMSA slack: Even ACF/PACF plots would be really interesting to see autocorrelation within series, and if you can look at lags between series (e.g., prices of a GPU type jump one week after ETH jumps) it would make the analysis quite actionable

@driscoll42
Copy link
Owner Author

They're covered in the Time Series class, but totally understand if you haven't taken that. The concepts are pretty straight forward - they're measures of the autocorrelation between various points in a time series. So, you might find that what happens tomorrow is highly correlated to what happens today, what happens next week is somewhat correlated to what happens today, and what happens next month is completely uncorrelated. In R there's a function in the stats package - https://www.rdocumentation.org/packages/stats/versions/3.6.2/topics/acf
A helpful overview - https://online.stat.psu.edu/stat462/node/188/#:~:text=Autocorrelation%20and%20Partial%20Autocorrelation,%2C2%2C....&text=This%20value%20of%20k%20is,and%20is%20called%20the%20lag.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
ebayMarketAnalyzer
  
In progress
Development

No branches or pull requests

1 participant