Connect with us

Blockchain

Integrating Technical Indicators to Automated Bitcoin Trading Bot

In this tutorial, we’ll integrate a few most popular technical indicators into our Bitcoin trading bot to make it learn even better…

Avatar

Published

on

Although the graph seems very compressed due to the fact that it contains a lot of timeframes, looking at the bottom subplot you might see, that our MACD curve has a maximum and minimum pikes between +-300, and our RSI fluctuates between 0–100 I chose to normalize these values by dividing them by 400 and 100 respectively.

As you can see, this code part doesn’t change, except that we need to import the AddIndicators function, that we call in the 5th code line to process the whole dataset, other training steps are all the same.

I used the following parameters to train our model:

training start: 2021-01-18 22:18
initial_balance: 1000
training episodes: 50000
lookback_window_size: 50
lr: 1e-05
epochs: 5
batch size: 32
normalize_value: 40000
model: Dense
training end: 2021-01-19 14:20

As you can see, the parameters are quite the same as in my series of previous tutorials and as a result, our training took around 16 hours. But actually, we are here not about the training part, but testing, so I ran the following code to test our trained model:

After running the above code to test our Bitcoin trading bot against an unseen test dataset we received quite nice results:

test episodes: 1000
net worth: 1078.6216040753616,
orders per episode: 135.945
no profit episodes: 1
comment: Dense network

If we would compare these results with the previous tutorial following results:

net worth: 1054.483903083776
orders per episode: 140.566
no profit episodes: 14

We can see that we obviously have better results, it doesn’t matter that the bot makes fewer orders per episode, but it makes 2% more profit than before, and most importantly it had only one episode that finished in negative net worth.

In summary, our bot made close to 8% profit from unseen data while trading Bitcoin in perfect conditions, that’s amazing results!

If we would like to see what orders our bot makes with all the indicators and etc. we should change the following Show_reward=True, Show_indicators=True, visualize=True parameters and while running our same testing code, we may see similar results:

Up to this point, during all previous tutorials, we were training and testing our agents within the same historical data, but I think everyone is interested in how this bot would perform with more training data and with the current Bitcoin price? So to solve this, I thought that in the next tutorial I’ll write about downloading historical data from the Cryptocurrency market and do the training!

Of course, because we’ll have much more training data we may face a problem that our training may take days, so I’ll try to solve this that we could run multiple simulated trading environments at once (for example 16 environments) so that we could spend less time while training. More about in the next tutorial, see you there!

Thanks for reading! As always, all the code given in this tutorial can be found on my GitHub page and is free to use!

Source: https://medium.com/analytics-vidhya/integrating-technical-indicators-to-automated-bitcoin-trading-bot-b8f6258a17a6?source=rss——-8—————–cryptocurrency

Blockchain

Bitfarms hints at massive expansion as it purchased 48,000 new ASIC miners from MicroBT

Canadian block reward mining operators Bitfarms Ltd. has confirmed its latest purchase of 48,000 new ASIC miners from MicroBT. Once operational, they expect the new miners to increase their hashing capacity by approximately 5.0 EH. According to the press release, the purchase is a continuation of the growing relationship between the hardware manufacture and Bitfarms. […]

Avatar

Published

on

Canadian block reward mining operators Bitfarms Ltd. has confirmed its latest purchase of 48,000 new ASIC miners from MicroBT. Once operational, they expect the new miners to increase their hashing capacity by approximately 5.0 EH. According to the press release, the purchase is a continuation of the growing relationship between the hardware manufacture and Bitfarms. […] Checkout PrimeXBT
Trade with the Official CFD Partners of AC Milan
Source: https://coinnounce.com/bitfarm-hints-at-massive-expansion-as-it-purchased-48000-new-asic-miners/

Continue Reading

Blockchain

Centra Tech Founder Sentenced to 8-years in Prison For $36M Crypto ICO Fraud

Sohrab “Sam” Sharma, the founder of defunct cryptocurrency firm Centra Tech was sentenced to 8-years in prison for duping investors out of $36 million. The firm had hired high-profile celebrities including Floyd Mayweather and DJ Khaled whom the firm paid for promotions to lure more investors. Sharma pled guilty to conspiring to commit securities fraud,

The post Centra Tech Founder Sentenced to 8-years in Prison For $36M Crypto ICO Fraud appeared first on Coingape.

Avatar

Published

on

fraudulent ICO

Sohrab “Sam” Sharma, the founder of defunct cryptocurrency firm Centra Tech was sentenced to 8-years in prison for duping investors out of $36 million. The firm had hired high-profile celebrities including Floyd Mayweather and DJ Khaled whom the firm paid for promotions to lure more investors. Sharma pled guilty to conspiring to commit securities fraud, wire fraud, and mail fraud as part of an initial coin offering.

Centra Tech was one of the many crypto companies to lure heavy investment during the 2017-18 ICO frenzy on the pretext of launching a cryptocurrency in the near future. Sharma along with two of his recruits managed to raise nearly $25 million through social media promotions and mentions from high-profile celebrities. Both Khaled and Mayweather later settled with the SEC for failing to disclose they have been paid to promote the project.

While prosecutors sought 14-15 years jail term for the founder, Sharma’s counsel pleaded for a two and a half year term claiming the defendant was not the evil behind the fraud.

Sharma said,

“I am deeply sorry and devastated for what my actions have done to those who believed in me and my vision. I wanted to fake it till I made it, and I was hoping that the ends justified the means.”

As per the plea deal, Sharma forfeited 100,000 ETH raised from the sale of the digital token of his company.

Centra Tech Reflects Everything Wrong With ICO Era

The hype around cryptocurrencies in 2017 gave rise to Initial Coin Offering (ICOs) and an easy way of raising funds to develop and launch new crypto tokens. In what many called a revolution in fundraising soon turned into a playground for fraudsters and scams. It was estimated more than 90% of the projects were either scams or never made it to any exchange for one reason or the other.

Centra Tech was no different, where the project was misleading investors on nearly every aspect right from claiming that it is being headed by a Harvard-educated chief executive officer with decades of business experience. Sharma also lied about having operational licenses in more than three dozens states and partnerships with payment processing giants such as Visa and Mastercard.

The post Centra Tech Founder Sentenced to 8-years in Prison For $36M Crypto ICO Fraud appeared first on Coingape.

Checkout PrimeXBT
Trade with the Official CFD Partners of AC Milan
Source: https://coingape.com/centra-tech-founder-sentenced-to-8-years-in-prison-for-36m-crypto-ico-fraud/

Continue Reading

Blockchain

Coinbase Registers Second 12K Bitcoin (BTC) Outflow In A Week, U.S. Institutional Buyers Holding Strongly

In a broader cryptocurrency market correction, the Bitcoin (BTC) price has tanked 6% today slipping below $47,000. As of press time, BTC is trading at a rate of $46,784 with a market cap of $875 billion. The latest Bitcoin price correction comes amid the drying up of trading volumes. However, it turns out that institutional

The post Coinbase Registers Second 12K Bitcoin (BTC) Outflow In A Week, U.S. Institutional Buyers Holding Strongly appeared first on Coingape.

Avatar

Published

on

In a broader cryptocurrency market correction, the Bitcoin (BTC) price has tanked 6% today slipping below $47,000. As of press time, BTC is trading at a rate of $46,784 with a market cap of $875 billion. The latest Bitcoin price correction comes amid the drying up of trading volumes.

However, it turns out that institutional players, especially from the U.S, have been scooping a huge amount of Bitcoins at every correction. As per the latest update from CryptoQuant CEO Ki-Young Ju, a second major Bitcoin-outflow of 12K Bitcoins recently took place at the Coinbase exchange. The first one happened earlier this week three days back on March 3.

As Coingape reported, the Bitcoin whales have been accumulating BTC even when the price dropped $44,000 levels ahead this week. But it seems that the whales are majorly coming this time from the U.S. Over the last year, it seems that Asian whales have been losing all their supplies to the U.S. institutions and corporates who have gone currently on an accumulation spree.

As reported by Chinese reporter Wu Blockchain:

“In the past year, the BTC holdings in Asia have fallen more than 400,000, and the BTC holdings in North America (represented by US) have increased by more than 600,000. This prove again that Chinese holds are selling and American institutions are buying”.

Courtesy: Grayscale, Chainalysis

U.S. Institutions Haven’t Sold Any Bitcoin

The U.S. institutions have been buying Bitcoins heavily since the beginning of 2021. While Bitcoin has gone through several cycles of surge and drop, over the last two months. However, Ki-Young Ju presents another interesting piece of data showing that U.S. institutions haven’t sold a dime since December 23. He writes:

“It seems most US institutions haven’t sold any Bitcoin since their OTC deals. For example, here are custody wallets from Coinbase outflows on Dec 23, 2020. No $BTC moved since then. Remember, institutions like @tesla are with us”.

U.S. bulls are buying aggressively in this market and continue with their purchases ahead. Grayscale has added over 50,000 Bitcoins this year for its Bitcoin Trust (GBTC). Another bullish indicator is that the Network Realized Profit or Loss (NPL) for Bitcoin is at its lowest point.

https://twitter.com/santimentfeed/status/1367559646936973316

The post Coinbase Registers Second 12K Bitcoin (BTC) Outflow In A Week, U.S. Institutional Buyers Holding Strongly appeared first on Coingape.

Checkout PrimeXBT
Trade with the Official CFD Partners of AC Milan
Source: https://coingape.com/coinbase-registers-second-12k-bitcoin-btc-outflow-in-a-week-u-s-institutional-buyers-holding-strongly/

Continue Reading

Blockchain

Bitcoin Retraces After Bouncing, Falling Below $47,000

Bitcoin is approaching a crucial support area. A strong resurgence will be mandatory for the possibility of bullish continuation to remain.   Bitcoin Bounce Retraces On Feb. 28, BTC reached the $45,000 support area and bounced upwards. It proceeded to reach a high of $52,652 four days later but has been moving downwards since. So … Continued

The post Bitcoin Retraces After Bouncing, Falling Below $47,000 appeared first on BeInCrypto.

Avatar

Published

on

The Bitcoin (BTC) price has been retracing since getting rejected by the $52,500 resistance area on March 3.

Bitcoin is approaching a crucial support area. A strong resurgence will be mandatory for the possibility of bullish continuation to remain.

 

Bitcoin Bounce Retraces

On Feb. 28, BTC reached the $45,000 support area and bounced upwards. It proceeded to reach a high of $52,652 four days later but has been moving downwards since.

So far, BTC has reached a low of $46,294 in the early hours of March 5. This is still inside the body of the bullish candlestick of March 1. Therefore, it’s still inside the parameters of a normal retracement. 

However, both the MACD and Stochastic oscillator are bearish. The latter has already made a bearish cross. On the other hand, the RSI is trying to hold on above the 50-line.

BTC Daily Movement
BTC Chart By TradingView

Bitcoin Struggles to Find Support

The six-hour chart shows that the main resistance area is found at $52,476. This is the 0.618 Fib retracement of the most recent downward movement and a horizontal resistance area. 

Therefore, until BTC manages to clear it, we cannot consider the trend bullish — at least not in the short/medium-term.

Similar to the daily time-frame, the MACD and RSI are bearish.

BTC Six-Hour
BTC Chart By TradingView

Finally, the two-hour chart shows that BTC is still above the $46,600 support area (0.618 Fib retracement). 

However, there are no bullish reversal signs yet.

If BTC were to break down, the next closest support area would be found at $45,000. This is the 0.786 Fib level of the most recent move and a horizontal support area from the daily chart. 

Therefore, the loss of this level would be a significant bearish development for BTC.

BTC Short-Term
BTC Chart By TradingView

Corrective Decrease?

A look at the very short-term 15-minute chart shows a continued decrease that has been ongoing since March 3. 

The downward movement is perfectly channeling, and the significant overlap suggests that it’s likely to be corrective. This means that despite the lack of bullish reversal signs, an eventual breakout is expected.

BTC Correction
BTC Chart By TradingView

The most likely wave count suggests another upward move towards a new all-time high. 

However, a decrease below the Feb. 28 low would signal that BTC is likely to fall towards $40,000.

BTC wave Count
BTC Chart By TradingView

Conclusion

Bitcoin is expected to find relief at one of the support levels outlined and continue moving higher.

The loss of the $45,000 support area would be a major bearish development, indicating that the local low might not be in yet.

For BeInCrypto’s previous Bitcoin (BTC) analysis, click here.

The post Bitcoin Retraces After Bouncing, Falling Below $47,000 appeared first on BeInCrypto.

Checkout PrimeXBT
Trade with the Official CFD Partners of AC Milan
Source: https://beincrypto.com/bitcoin-retraces-after-bouncing-falling-below-47000/

Continue Reading
Blockchain38 mins ago

Bitfarms hints at massive expansion as it purchased 48,000 new ASIC miners from MicroBT

Blockchain46 mins ago

Centra Tech Founder Sentenced to 8-years in Prison For $36M Crypto ICO Fraud

Blockchain52 mins ago

Coinbase Registers Second 12K Bitcoin (BTC) Outflow In A Week, U.S. Institutional Buyers Holding Strongly

Blockchain1 hour ago

Bitcoin Retraces After Bouncing, Falling Below $47,000

Blockchain1 hour ago

Ripple’s Asia expansion unaffected by SEC lawsuit, says CEO

Blockchain1 hour ago

Thailand’s largest movie theater chain accepts Bitcoin

Blockchain2 hours ago

Bitcoin Support at $47K “Very Strong,” Glassnode CTO Asserts After Price Falls

Blockchain2 hours ago

MicroStrategy Stock, Bitcoin Price Take a Synchronized Tumble

Blockchain2 hours ago

NBA team Dallas Mavericks to accept Dogecoin for payments.

Blockchain2 hours ago

Yield Protocol Listing in Gate.io

Blockchain2 hours ago

Dogecoin (DOGE) Gets a Boost with BitPay, Coinflip’s Payment Support

Blockchain3 hours ago

Should Tesla sell its Bitcoin position? Here’s a former Goldman Sachs exec’s take

Blockchain3 hours ago

DeFi, the future of Finance: How ‘Value DeFi’ is bringing Fairness, True Value and Innovation to Decentralized Finance

Blockchain3 hours ago

DOT & ADA Price Analysis: Will the Altcoins Flip to Their Previous Positions?

Blockchain3 hours ago

ETH/USD Price Analysis: ETH/USD Should Break Above $1500 Target on Its Way Past $2,000

Blockchain3 hours ago

Powell Comments Leaves Bitcoin Market Sour; Bearish Assault Ahead?

Blockchain3 hours ago

XRP Price Continue to Rally Despite a Bloodbath in the Crypto Space

Blockchain3 hours ago

HBAR Bullish Over $0.16 – Technical Analysis

Blockchain3 hours ago

Grayscale Purchases Litecoin, Ethereum Classic, and Bitcoin Cash

Blockchain3 hours ago

Cryptocurrency Market Faces Resistance as Bitcoin Drops below $47,000

Blockchain3 hours ago

Thai Police Charge Celebrity Actress for Forex-3D Connections

Blockchain3 hours ago

SEC’s actions caused $15 billion in damages to XRP holders: Ripple

Blockchain3 hours ago

City of Reno to create the “Reno DAO” on Tezos and digitize famous art pieces as NFTS

Blockchain4 hours ago

Crypto Sentiment Shines in Goldman Sachs Client Survey

Blockchain4 hours ago

How to Protect Yourself from the Cryptojacking Threat

Blockchain4 hours ago

BNT Uptrend to Continue Above $7 – Technical Analysis

Blockchain4 hours ago

NBA Team to Accept Dogecoin for Payments

Blockchain4 hours ago

Mike McGlone Predicts Bitcoin Could Soon Hit $100,000

Blockchain4 hours ago

Ripple’s Brad Garlinghouse, Chris Larsen File Motions To Dismiss SEC Lawsuit

Blockchain4 hours ago

Ripple’s Brad Garlinghouse, Chris Larsen File Motions To Dismiss SEC Lawsuit

Trending