I think it would be advantageous to be able to return historical information for crypto coins against a different crypto/currency instead of just against the default of the crypto vs usd pairing.
For example:
The data from https://www.investing.com/crypto/vechain/ven-usd is currently returned when
investpy.get_crypto_historical_data(crypto='vechain',
from_date='01/01/2012',
to_date=today) is called.
I think you would need to modify the crypto.py file and change the get_crypto_historical_data function.
I see in the params variable, the crypto_id is included and has been obtained previously from a csv file within the package. Perhaps it would be possible to include coin pairings within the csv file included with the package.
Or maybe we can rewrite the function slightly and add another variable 'reference_currency':
investpy.get_crypto_historical_data(crypto='vechain', reference = 'btc'
from_date='01/01/2012',
to_date=today)
returns information from https://www.investing.com/crypto/vechain/ven-btc
and if the reference_currency is not provided, the default behaviour is to return data from the usd pair as it currently works.
I think it would be advantageous to be able to return historical information for crypto coins against a different crypto/currency instead of just against the default of the crypto vs usd pairing.
For example: The data from https://www.investing.com/crypto/vechain/ven-usd is currently returned when investpy.get_crypto_historical_data(crypto='vechain', from_date='01/01/2012', to_date=today) is called.
But it could be useful to instead return the data showing data of one crypto against another crypto: For example vs btc: https://www.investing.com/crypto/vechain/ven-btc Or vs another currency like eur: https://www.investing.com/crypto/vechain/ven-eur
I think you would need to modify the crypto.py file and change the get_crypto_historical_data function.
I see in the params variable, the crypto_id is included and has been obtained previously from a csv file within the package. Perhaps it would be possible to include coin pairings within the csv file included with the package.
Or maybe we can rewrite the function slightly and add another variable 'reference_currency': investpy.get_crypto_historical_data(crypto='vechain', reference = 'btc' from_date='01/01/2012', to_date=today) returns information from https://www.investing.com/crypto/vechain/ven-btc and if the reference_currency is not provided, the default behaviour is to return data from the usd pair as it currently works.