[English] Brazilian Fund Scrapper (or brfunds) is a package to recover data from investment funds without the need to download data to your computer. It uses the data available on https://comparadordefundos.com.br/ and can be used to Time Series Analysis of earnings, net assets and number of shareholders. It can also be used for comparing rentability of different funds.
Ps: Due to changes on the api, the search is done exclusively with the CNPJ of the fund (company id), this changed occured starting on version 0.2.0.
[Português] Brazilian Fund Scrapper (ou brfunds) é um pacote para obter dados de fundos de investimentos brasileiros sem precisar baixar arquivos para o drive do computador. Ele utiliza o banco de dados disponível em https://comparadordefundos.com.br/ e pode ser usado para Análise de Séries Temporais da rentabilidade, patrimônio do fundo e do número de cotistas.
Obs: Por conta de mudanças na api, a busca pelos fundos é feita exclusivamente pelo CNPJ do fundo, a mudança é válida a partir da versão 0.2.0.
Examples:
from brfunds import searchFund
#The search fuction can be used to get the fund CNPJ (brazilian company id)
# The max_size param can be used to control the size of the search
searchFund('Example Fund', max_size = 1)
| Name | CNPJ |
|---|---|
| Example Fund 1 | 00.000.000/0000-00 |
from brfunds import getFundsEarnings
#With the CNPJ, you can get data from the statistic of the fund
getFundsEarnings('00.000.000/0000-00')
| Date | Example Fund 1 |
|---|---|
| 2016-01-31 | 0.000000 |
| 2016-02-01 | -0.000715 |
| 2016-02-06 | -0.009902 |
| 2016-02-07 | -0.009009 |
| 2016-02-08 | -0.007612 |
| ... | ... |
| 2021-06-02 | 0.910064 |
| 2021-06-04 | 0.914201 |
| 2021-06-07 | 0.917008 |
| 2021-06-08 | 0.911554 |
| 2021-06-09 | 0.911601 |
#It can also be used to multiple funds and benchmarks
getFundsEarnings('00.000.000/0000-00','00.000.000/0000-00', benchmarks = ['cdi','ibovespa'], start = '31/01/16', end = '09/06/21')
| Date | Example Fund 1 | Example Fund 2 | CDI | IBOV |
|---|---|---|---|---|
| 2016-01-31 | 0.000000 | 0.00000 | 0.00000 | 0.00000 |
| 2016-02-01 | -0.000715 | 0.001136 | 0.000525 | -0.048653 |
| 2016-02-06 | -0.009902 | -0.005026 | 0.001049 | -0.024186 |
| 2016-02-07 | -0.009009 | -0.006855 | 0.001575 | 0.006204 |
| 2016-02-08 | -0.007612 | -0.009379 | 0.002100 | 0.000544 |
| ... | ... | ... | ... | ... |
| 2021-06-02 | 0.910064 | 1.324291 | 0.450420 | 2.194512 |
| 2021-06-04 | 0.914201 | 1.323814 | 0.450612 | 2.207436 |
| 2021-06-07 | 0.917008 | 1.323690 | 0.450805 | 2.22347 |
| 2021-06-08 | 0.911554 | 1.327529 | 0.450997 | 2.199088 |
| 2021-06-09 | 0.911601 | 1.329402 | 0.451190 | 2.202039 |
#The package also includes functions for drawdown, 30d Volatility, Number of Shareholders and Net Worth.
getFundsDrawdown('00.000.000/0000-00','00.000.000/0000-00', start = '08/01/20')
getFundsVolatility('00.000.000/0000-00', start = '13/10/20')
getFundsShareholders('00.000.000/0000-00','00.000.000/0000-00')
getFundsNetWorth('00.000.000/0000-00', end = '31/12/18')
Metadata
Release files for brfunds 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| brfunds-0.2.1.tar.gz | 7.3 kB | Without provenance | Details for brfunds-0.2.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| brfunds-0.2.1-py3-none-any.whl | Python 3 | none | any | Details for brfunds-0.2.1-py3-none-any.whl |
Total release size: 14.8 kB
Release files / brfunds-0.2.1.tar.gz
| Download URL | brfunds-0.2.1.tar.gz |
|---|---|
| Size | 7.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
41cd8b1b7ee98c5674ba85ad999d82d6cbc69945f60b5196188582117a33ff42
|
|
BLAKE2b-256 checksum How to use checksums |
19ce010ff9bc89d2002d2b89c006c7400a2e0a3bba334a8f4e7adaf875d91aed
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.13
|
Release files / brfunds-0.2.1-py3-none-any.whl
| Download URL | brfunds-0.2.1-py3-none-any.whl |
|---|---|
| Size | 7.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e3279ced7fe4af59bad48b5a82b1e6d7e7bd98d179addbcf253ad5c934a86b99
|
|
BLAKE2b-256 checksum How to use checksums |
6ecebc49651825ad0977cc6073dd55ed3382f27f7a85706276b142985189d51f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.13
|
Security for brfunds 0.2.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.