Bitcoin Forum
June 14, 2024, 03:37:33 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
  Home Help Search Login Register More  
  Show Posts
Pages: « 1 ... 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 [136] 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 ... 202 »
2701  Bitcoin / Bitcoin Discussion / Re: Is Bitcoin mining a zero-sum game? Or is it a race to the top? on: June 09, 2022, 07:05:39 PM
With the current chip crisis and disruption of supply chains, the remaining chips will be valuable and will be used in industries that generate millions or billions instead of Bitcoin mining.

The more companies engaged in mining, the more efficient and decentralized the network, and it is also impossible to think that countries or entities will join to buy bitcoin without managing mining farms or even entire contracts.

I expect that after 50 years, if the price of Bitcoin increases significantly, the purpose of mining profits will not be to produce more coins, but to ensure that the entire network operates without interference from one of the parties.
2702  Economy / Service Discussion / Re: Is CoinGate a good option for accepting BTC payments? on: June 09, 2022, 06:40:21 PM
Do you have any experience with them? Any thoughts?
If there are many people making small payments and a lot of daily trading volumes then the CoinGate option will be convenient first then the 1% fee can be very expensive so it is best to run some open source software.

They have an account in this forum, ask them and they will respond to you https://bitcointalk.org/index.php?action=profile;u=787273

I made this list you can read it Bitcoin Payment Processors https://bitcointalk.org/index.php?topic=5259548.0
2703  Economy / Exchanges / Re: Edge issues Mastercard without KYC on: June 09, 2022, 04:10:40 PM
What services will accept this card and what fees or data that they will be collected from the user.


  • I don't think that you will maintain your privacy while using a MasterCard card, and this will not last long or in high volumes.
  • I don't think PayPal, Google, Apple and other well-known services will accept these cards.

I'm not really sure how this company is making money though:

There may be additional fees with each purchase or sale, or issuance fees, they will make profits even from selling data so it is not a problem.
2704  Economy / Trading Discussion / Bitcoin Backtesting on: June 08, 2022, 08:07:51 PM

Disclaimer: This article is intended for and only to be used for reference purposes only, Google it again, check sources and DYOR.


Table of contents

      1. What Is Backtesting?
      2. Manual Backtesting
      3. Systematically Backtesting a Strategy
      4. Bitmex Data python code






Introduction

If you are a trader then backtesting is the essential test in developing your trading strategy where you will re-test your trading strategy through historical or past data and thus see what the results will be if you apply it to live data.
However, if backtesting is not done accurately, you will get false results and therefore when you make a trade on the platform it will cause losses.

Therefore, it is a double-edged sword, but doing it correctly will lead you to good results in the cryptocurrency market, especially for those who trade a lot.

Backtesting does not guarantee profits, but it is an ideal way to test whether it is effective or not. However, unreliable data can affect the backtesting process.





Manual Backtesting


It is the way we do it often, where the decision is made based on tracking the latest historical data or certain candles, taking into account some technical indicators, and then building a trading strategy by placing a buy or sell signal in the market.

Mostly, all the user does is use programs like TradingView where he chooses a trading strategy and then presses the restart button and chooses a period in history to start testing.

Based on the results of this test, the trader makes a discretionary decision to buy or sell and may build his or her strategy using an Excel spreadsheet.
Therefore, manual trading is easy and reduces dependence on emotions by studying some market data, but it is not strong enough, as you are doing a non-analytical study of a small part of the historical data, and therefore you may achieve some losses, especially if the recent data is in a certain upward trend.




Systematically Backtesting a Strategy

The main difference here is that the user has more accurate data due to the processing power of computers and the suitability of some programs and thus the possibility of comparing more historical data and using in-depth statistics about their strategy and thus determining whether it is appropriate or not.

The method is data acquisition, historical data requirements, OHLCV, book data request.

Historical data requirements
Trading costs such as commissions and exchange rate differences can lead to inaccuracies in calculating profits and thus deducting more money from profits.

Two different types of market data are used, candlestick and order book data, but order book data is usually more reliable.

OHLCV candlestick data:

OHLCV candles data (Open-High-Low-Close-Volume) OHLCV is basically a spreadsheet of OHLC price data for each time period of the chart timeframe.

The main problem with this method is to ensure that there is sufficient liquidity to support your trading activity, and therefore buy and sell orders may not be executed accurately, and thus may cause losses, but they are easier to obtain.

Book data request

The order book is better than candlestick data. Because it includes market price, size, and depth, and thus a better representation of the orders available at any time.



Bitmex Data python code


The first step is to get and download the data. Bitmex have trading files that are publicly available to download, you can download it from here https://public.bitmex.com/?prefix=data/trade/

Now define the date range for trading data. In our case, we can set it from October 2020.

Code:
import pandas as pd
date_from = "2020-10-01"
date_to = "2020-10-31"
dates = pd.date_range(date_from, date_to).astype(str).str.replace("-", "")


Now define a function that downloads a trading file and saves it to a folder.

Code:
import requests
from os import path
BASE_URL = "https://s3-eu-west-1.amazonaws.com/public.bitmex.com/data/trade/%s"

def download_trade_file(filename, output_folder):
    print(f"Downloading {filename} file")
    url = BASE_URL % filename
    resp = requests.get(url)
    if resp.status_code != 200:
        print(f"Cannot download the {filename} file. Status code: {resp.status_code}")
        return
    with open(path.join(output_folder, filename), "wb") as f:
        f.write(resp.content)
    print(f"{filename} downloaded")

Now iterate through dates and download daily file that end with .csv.gz

Code:
output_folder = "data/bitmex"
for date in dates:
    filename = date + ".csv.gz"
    download_trade_file(filename, output_folder)


import glob
filepaths = glob.glob(path.join(output_folder, "*.csv.gz"))
filepaths = sorted(filepaths)
filepaths

our data will be looks like


As we see above, each trade is in own row. Backtrader doesn't know how to work with this data format so we need to convert it to OHLC format (Open, High, Low, Close).

Code:
df = df.groupby(pd.Grouper(key="Datetime", freq="1Min")).agg(
    {"price": ["first", "max", "min", "last"], "foreignNotional": "sum"}
)
df.columns = ["Open", "High", "Low", "Close", "Volume"]
df.loc[:, "OpenInterest"] = 0.0 # required by backtrader
df = df[df.Close.notnull()]
df.reset_index(inplace=True)

Now you get your data as OHLC format and ready to test it.




Sources
Code:


https://medium.com/swlh/backtesting-a-bitcoin-trading-strategy-96ea854762bc
https://alpaca.markets/learn/backtesting-bitcoin-with-pandas-and-market-data-api/
https://romanorac.medium.com/
https://www.cryptohopper.com/features/backtesting
https://learn.bybit.com/strategies/backtesting-crypto-trading-strategies/

2705  Economy / Service Discussion / Re: CoinGate vs BitPay? on: June 08, 2022, 07:29:56 PM
I have prepared this list, please read it Bitcoin Payment Processors https://bitcointalk.org/index.php?topic=5259548.0

If the option is exclusively between CoinGate and BitPay, I will go with CoinGate for the following reasons:

  • There are no problems with the customer: BitPay banned clients from some countries, which may reduce your profits.
  • All CoinGate problems are related to verifying the identity of the store: If you pass KYC test, you will not face many future problems.
  • Quick deposit and transfers to your bank account
  • Support more cryptos
  • An active support team
  • Low Fees
2706  Economy / Service Announcements / Re: Forget about exchanger search! Use BestChange! on: June 08, 2022, 07:04:45 PM
Are there any plans to include direct transfer between cryptocurrencies? A Widget (GUI) allows the user to directly exchanges using APIs, then choose the platform and transfer instead of visiting the platform link.

Something like what changelly.com offer with many wallets like exodus and trust wallet

2707  Economy / Services / Re: [OPEN] Win.com | Play-to-Earn Gaming Infrastructure for Web3 | Sig Campaign Sr.+ on: June 08, 2022, 06:37:41 PM
Bitcointalk profile link: https://bitcointalk.org/index.php?action=profile;u=1701092
Current amount of posts: 1345
EARNED merit in the last 120 days: 74
bech32 BTC address for Payouts: bc1qygn7y00z6metlwaferdcykp28gd22w4nt74zmu
2708  Economy / Trading Discussion / Re: Copy/signal trading platform with REAL verified results - need feedback on: June 08, 2022, 11:16:15 AM
The best I can tell you is to avoid data manipulate that give the impression that the result of your trades or signals is profitable, put the real results and share the old evidence even if it leads to losses.

  • In the beginning it will be impossible to trust you and therefore this information must be free, verifiable, and linked to currencies with high market capacities and preferably only Bitcoin.
  • The more people visit your site, the more data you will gain, and if you deal with that data with an analysis, you will get more accurate results.
  • Stay away from all forms of fraud or profit from users or false recommendations.


Profits will come in the future after you gain an audience and then you can add more currencies and the profit will be from advertisements.
Your credibility and truth data is the key to your profits.
2709  Other / Meta / Re: Not sure where to ask this. So lets try here. on: June 08, 2022, 11:06:24 AM
Deleting accounts doesn't mess up any threads, like this thread. It just changes to anonymous, with no profile information. Post stays intact.

As you can see here, I only change the username to "Anonymous" on request.
I still can say that "Anonymous" username it is "tysat" click on last edit topic and will see it.
2710  Economy / Services / Re: [OPEN] BestChange Signature Campaign | Sr Member+ on: June 08, 2022, 10:59:05 AM
Bitcointalk Profile: https://bitcointalk.org/index.php?action=profile;u=1701092;
Current post count(including this): 1349
Amount of merits for the last 120 days: 200
BTC Address: 35TcgRH3n463DveQc6YjoAgtN5BbSqzMAq
2711  Other / Beginners & Help / Re: Creating a prepared mindset before the reality emerged. on: June 05, 2022, 09:47:49 AM
The economy today is variable and requires the average user to have a detailed knowledge, even in general, of the economy, otherwise he will be forced to work overtime for nothing but that he has not learned the basics about the economy.

Bitcoin is one of the great solutions to these economic problems, but just like any solution, if the appropriate mechanisms are not taken with it, it will eventually turn into another problem.
2712  Economy / Economics / Re: LMAO: India resells Russian oil to the European Union. on: June 05, 2022, 09:41:24 AM
China was almost doing this with Iran. I wonder how India was not demonized or tried to prevent it from doing so.
If we read the numbers, it jumped from less than 200,000 barrels at the beginning of the year to less than 800,000 dollars.
It is not enough to solve the energy problem, and I think that the final consumer is the one who decides whether this step will succeed or not, just as happened with Shell (Shell agrees to sell Russian retail business to Lukoil - BBC).

Let's see how Russia will be able to sell about 3 million barrels that were going to Europe and its allies.
2713  Bitcoin / Bitcoin Discussion / Re: Chipotle now accepts crypto payments (only in US stores for now) on: June 04, 2022, 04:04:36 PM
It is good news, not because the company accepts payments, but rather indicates that Bitcoin has a popularity among individuals. The company will not make much profit by accepting these currencies, but it is an indirect proof of the popularity of Bitcoin.

I hope that awareness and thinking about digital currencies will continue, not as an investment, but as money and a good investment in the long run. People may not be inclined to spend them like dollars, but you will be happy with the experience of paying using them.
2714  Bitcoin / Bitcoin Discussion / Re: How do you feel when the market is downtrend? on: June 04, 2022, 03:43:18 PM
A bear market is good for anyone who:

  • You do not want those investments during the next three years.
  • For those who have a surplus of cash and wish to invest it.
  • For those looking for a long-term investment with low risks.

Profit is possible on the date of purchase, and most likely, if we break the previous top, we will not return to the levels of 30 thousand dollars again.
2715  Other / Politics & Society / Re: Did Biden receive another middle finger from Saudis? (Taiwan was abandoned) on: June 04, 2022, 03:34:58 PM
The Kingdom of Saudi Arabia depends mainly on the United States in matters of security and defense, so I do not expect that deep differences will occur between the two parties, but the US policy towards this ally seems strange, as the Saudi file on human rights has been criticized, especially in the case of the Khashoggi assassination (Assassination of Jamal Khashoggi - Wikipedia,) and there is a war in Yemen In which the United States did not provide sufficient support, it seems that the policy of the United States to the Gulf states needs to change.

Several years ago, the United States tried to support the failed coup in Turkey (2016 Turkish coup d'état attempt - Wikipedia,) the inflation that occurred and continued for a while, the government's support for some elements of the opposition in Syria, and the missile problem with Russia, all of which will complicate relations if we ignore hyperinflation.
2716  Alternate cryptocurrencies / Altcoin Discussion / Re: Crypto Price Up & Down is normal be patient All Crypto Holders on: June 04, 2022, 03:18:55 PM
The comparison you mentioned is illogical, you did not compare cryptocurrencies on several big down trend, but rather on dwon or one major correction, but most of them fail to achieve gains after they collapse for the first time.


  • Ethereum coin only tested one time.
  • Dogecoin gained fame because of Elon Musk and don't expect to back to ATH.
  • Shiba INU is just a worthless copy of Dogecoin and has no value, you will lose your money if you invest in it for the long term
2717  Economy / Service Discussion / Re: How anyone ever heard or used this Crypto trading site? on: June 04, 2022, 03:06:16 PM
It seems that you chose the wrong place to try to promote the scam project, and I am sure that the members above have given all these negative reviews without even getting 10 visits to the site.
I advise you to move away from these old methods of scamming and try to build something useful.

Cryptocurrency trading means that you are guaranteed that the trading platform will accept your money and that there are enough trading volumes which is something that does not happen to a new platform that does not get enough traffic.
2718  Economy / Economics / Re: Jamie Dimon says ‘brace yourself’ for an economic hurricane on: June 03, 2022, 03:25:10 PM
The news changes quickly. A month ago, I remember that everyone started talking suddenly that inflation got out of control and that they were wrong and that the Central Bank will focus on fighting inflation and will succeed in doing so.

This talk did not last for a month, and now we see analyzes saying that stagflation and stagflation are coming, and that we have to prepare to confront it. Inflation is not a major problem just like stagnation.

I think the second and third quarters of this year are going to be very epic although I think we'll wipe out all those losses by the fourth quarter.

will the recession, stagflation,quantitative tightening Dump bitcoin?
2719  Bitcoin / Bitcoin Discussion / Re: Goldman Sachs Group lends money to Coinbase backed by bitcoins on: June 03, 2022, 03:11:38 PM
Does anyone know the history of the borrowing? Determine whether it was before the interest rate hike and the bitcoin price drop, or before that? What does a loan paid in bitcoin mean?

If I want to borrow $30,000 and say I put Bitcoin as collateral, will lenders treat Bitcoin as an asset or because of its price? If the price drops to 10,000, I will be asked to put 2 additional bitcoins as collateral?
2720  Economy / Service Announcements / Re: Coinriders 2.0 is here + survey on: June 03, 2022, 02:51:48 PM
Dark mode works fine but I see that the interface is somewhat similar to most currency tracking sites.

The prediction is useless, I note that the predictions for Bitcoin by the end of the current year and there are no predictions in the short term and all of them are illogical ($100,000.00) and this silly reason.


Quote
Description: I think bitcoin will hit $100,000 this year 2022 because alot of investors are waiting for this to happen, many investors expected it to happen last year 2021 but it didn't, I think it will happen this year as many are already anticipating for it.

Quote
Description: ATH gonna be 82332 USD, then drop sharply to 45-50k and people will claim bitcoin is dead


Logical one:

Quote
Description: For a while we think we entered a bear market then the crypto is booming so we can't really know. Is very unpredictable . I think bitcoin will be around 60k this year and next year we will be bigger if everything will go smooth

The psychological barrier will be higher than one hundred thousand, although it is almost impossible to reach it with all the events that are going on in the world.
Pages: « 1 ... 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 [136] 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 ... 202 »
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!