Skip to main content

A Python Edinet xbrl file parser

Project description

https://badge.fury.io/py/edinet-xbrl.svg https://travis-ci.org/BuffetCode/edinet_xbrl.svg?branch=master

edinet_xbrl is a Python parser for Edinet xbrl files.

Installation

To install edinet_xbrl, simply:

$ pip install edinet_xbrl

How To Use

To download xbrl files from EDINET:

from edinet_xbrl.edinet_xbrl_downloader import EdinetXbrlDownloader

## init downloader
xbrl_downloader = EdinetXbrlDownloader()

## set a ticker you want to download xbrl file
ticker = "1234"
target_dir = "a target directory path"
xbrl_downloader.download_by_ticker(ticker, target_dir)

To get value from your xbrl files:

from edinet_xbrl.edinet_xbrl_parser import EdinetXbrlParser

## init parser
parser = EdinetXbrlParser()

## parse xbrl file and get data container
xbrl_file_path = "set your xbrl file path"
edinet_xbrl_object = parser.parse_file(xbrl_file_path)

## get value from container
key = "jppfs_cor:Assets"
context_ref = "CurrentYearInstant"
current_year_assets = edinet_xbrl_object.get_data_by_context_ref(key, context_ref).get_value()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for edinet-xbrl, version 0.2.0
Filename, size File type Python version Upload date Hashes
Filename, size edinet_xbrl-0.2.0.tar.gz (9.8 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page