Bitcoin Forum

Bitcoin => Bitcoin Discussion => Topic started by: nix10 on June 12, 2017, 07:57:30 PM



Title: [Updated] A naive analysis on investing in Bitcoins
Post by: nix10 on June 12, 2017, 07:57:30 PM
Hello all,

I am a, relatively, new cryptocurrency enthusiast owing to the large data they provide and the exceptional API mesh-ups that can be created using them. By heart, I am a Ruby developer but have started meddling with Python owing to the awesome quant capabilities it provides.

Over the last few months, after being initiated by my client, I have developed several strategies in backtrader library, various analysis on Buy and Hold investment strategies, different type of Portfolio creation as well as answers to questions like what kind of rebalancing works beautifully and at what time do we do such a rebalance of our portfolio?

Having done that, I did find some interesting results in my period of naive research. I am not perfect. My research ain't perfect. My data source ain't perfect (Poloniex), and my expertise with quant ain't perfect too (really new to Python), but I do want to help out. I want to present what I found in the naive hopes of helping community members.

I wanted to create a thread here with what I wanted to display. But, figured that posts were gonna be long and too much images, code, etc. may ruin the experience, and hence, created a website for the same. Its under-development at the moment.

So, here is my first post in this series (and, also on BitcoinTalk): http://coinalgo.com/2017/short-analysis-bitcoin-investment/

Would love to see any constructive criticism around this. I am here to stay for long and provide useful insights every week or sooner.


Title: Re: A short analysis of Bitcoin investment
Post by: Eron on June 12, 2017, 08:06:45 PM
Are you here to create a hedge fund or just to analyze ??


Title: Re: A short analysis of Bitcoin investment
Post by: nix10 on June 12, 2017, 08:09:34 PM
Just analyse things. I have no real monetary intentions here, apart from some analysis done for paid work, maybe.. sometimes...

My primary interest is in getting involved with the community here. And, what better way than to provide something that may be of use? :)


Title: Re: A short analysis of Bitcoin investment
Post by: odolvlobo on June 12, 2017, 08:45:16 PM
If you look closely, you will see that all your moving average graphs are shifted to the right slightly. That is because you assign the average value for a period to the end of the period instead of to the middle of the period. It doesn't make a big difference when looking at the graph all by itself, but it creates false impressions when comparing it directly to other graphs.


Title: Re: A short analysis of Bitcoin investment
Post by: nix10 on June 12, 2017, 09:09:51 PM
If you look closely, you will see that all your moving average graphs are shifted to the right slightly. That is because you assign the average value for a period to the end of the period instead of to the middle of the period. It doesn't make a big difference when looking at the graph all by itself, but it creates false impressions when comparing it directly to other graphs.

Well, moving averages here have not been shifted to the right, but instead they have not been calculated for the initial period of the SMA. Say, we are calculating a 30-day SMA for price - since, for the first 30 days, we don't have 30 points to calculate moving average on, it is difficult to calculate SMA in that period, which is why these periods have been omitted from the graph.

If you look closely, you will see that the ends align for the actual data and their SMA vs a shift.


Title: Re: A short analysis of Bitcoin investment
Post by: nix10 on June 12, 2017, 09:24:04 PM
Just added part 2 of this article: http://coinalgo.com/2017/short-analysis-bitcoin-investment-part-2/

This is nothing awesome to be honest. Just wanted to put a number on how much growth we could expect if we invested a recurring amount of money each day into BTC at any given time in the history.

Did you know, a $1 investment in BTC each day since April, 2016 (a total of $438) would be currently worth around $1800? Considering that $1 investment each day isn't a huge or risk-worthy amount as compared to an investment of $438 in one go. O'course, the latter would have earned higher profits, but given the volatility in the market, a recurring investment seems more rewarding here, IMO.


Title: Re: A short analysis of Bitcoin investment
Post by: odolvlobo on June 13, 2017, 07:23:50 AM
If you look closely, you will see that all your moving average graphs are shifted to the right slightly. That is because you assign the average value for a period to the end of the period instead of to the middle of the period. It doesn't make a big difference when looking at the graph all by itself, but it creates false impressions when comparing it directly to other graphs.

Well, moving averages here have not been shifted to the right, but instead they have not been calculated for the initial period of the SMA. Say, we are calculating a 30-day SMA for price - since, for the first 30 days, we don't have 30 points to calculate moving average on, it is difficult to calculate SMA in that period, which is why these periods have been omitted from the graph.

If you look closely, you will see that the ends align for the actual data and their SMA vs a shift.

You are, for example, assigning the average for the first 30 days to the 30th day in the graph. It works better if you assign it to the 15th day instead. Try it and you will see the graphs line up nicely instead of the SMA graph having a 15 day lag.


Title: Re: A short analysis of Bitcoin investment
Post by: nix10 on June 14, 2017, 02:37:30 AM
If you look closely, you will see that all your moving average graphs are shifted to the right slightly. That is because you assign the average value for a period to the end of the period instead of to the middle of the period. It doesn't make a big difference when looking at the graph all by itself, but it creates false impressions when comparing it directly to other graphs.

Well, moving averages here have not been shifted to the right, but instead they have not been calculated for the initial period of the SMA. Say, we are calculating a 30-day SMA for price - since, for the first 30 days, we don't have 30 points to calculate moving average on, it is difficult to calculate SMA in that period, which is why these periods have been omitted from the graph.

If you look closely, you will see that the ends align for the actual data and their SMA vs a shift.

You are, for example, assigning the average for the first 30 days to the 30th day in the graph. It works better if you assign it to the 15th day instead. Try it and you will see the graphs line up nicely instead of the SMA graph having a 15 day lag.

Well, SMAs are meant to be assigned like the way I did. We may get a better picture by assigning them to the middle of the observed period, but in that case it is a false picture. Consider this, we are mixing past values with the future values once you assign them to the 15th day. Do we know the future at any time?

Hence, SMAs represent the moving average over the last `n-1` days and the current day.