How to extract financial statements only using the Arelle Python API?

787 views
Skip to first unread message

Zeferinix Lihunger

unread,
Apr 21, 2016, 5:38:28 PM4/21/16
to Arelle-users
Hello Arelle-users and Arelle-devs,

Somehow, with the broken documentation on the Python API as of date, I managed to make the API work and successfully load an XBRL file.

Anyways, my question is: 
How do I extract only the STATEMENTS from the XBRL file? 

Below is a screenshot from Arelle's Windows App.

I tried experimenting with the API and here's my code

from arelle import Cntlr

xbrl
= Cntlr.Cntlr().modelManager.load('https://www.sec.gov/Archives/edgar/data/101984/000010198416000062/ueic-20151231.xml')

for fact in xbrl.facts:
   
print(fact)

but after executing this snippet, I'm bombarded with these:


I tried getting the keys available per modelFact and its a mixture between contextRef, id, decimals and unitRef which is not helpful from what I want to extract. With no documentation to help further with this, I'm at a loss here. Can someone enlighten me on how to achieve extracting only the statements?
Reply all
Reply to author
Forward
0 new messages