Explore data retrieved from SEC

In this section, we delve into the structure of the SEC data obtained from the API. The data follows a structured format in compliance with SEC reporting standards, utilizing XBRL (eXtensible Business Reporting Language). XBRL is a standardized language designed to enhance the accuracy and reliability of financial reporting.

Understanding XBRL

XBRL (eXtensible Business Reporting Language): XBRL is a structured, machine-readable format ensuring consistency and comparability across companies and filings. As specialized language for business and financial data, XBRL enables standardized communication and presentation of financial information. It uses XML (eXtensible Markup Language) to tag financial data with labels that provide context and meaning. This tagging allows for easier analysis, comparability, and extraction of data by both humans and machines.

Why XBRL?

  1. Consistency: XBRL ensures consistency in financial reporting by providing a standardized set of tags for financial concepts, making it easier to compare data across different companies and periods.

  2. Efficiency: The use of XBRL streamlines the process of collecting, analyzing, and disseminating financial information, reducing the need for manual data entry and interpretation.

  3. Transparency: XBRL enhances the transparency of financial data, as each financial concept is tagged with a specific label, providing clear identification and context.

Key Elements of XBRL in SEC Data

Within the SEC data retrieved through the API, XBRL is utilized to structure financial information.

A basic understanding XBRL1 is necessary for navigating and interpreting the structured financial data retrieved from the SEC. It ensures a standardized approach to financial reporting, facilitating meaningful analysis and comparison.

First, we load the required libraries and files.

Show the code
source("setup.qmd")          

Now, let’s retrieve the necessary objects for data exploration:

Show the code
# Load company_data
company_data <- readRDS("company_data.RDS")
cik <- readRDS("cik.RDS")

The data retrieved from the SEC API is structured financial data compliant with SEC reporting standards.

To navigate through this structure for analysis, consider the following key elements:

  • cik: The Central Index Key (CIK) is a unique identifier assigned to each company filing reports with the U.S. Securities and Exchange Commission (SEC).

  • entityName: This is the name of the company, in our case “JAKKS Pacific, Inc.”

  • facts: The main container for financial data, housing two critical sections:

    • dei: Contains Document and Entity Information (DEI), providing basic company details.

    • us-gaap: Holds financial data following the U.S. Generally Accepted Accounting Principles (GAAP).

Within these sections, financial data is organized as a list of items, each with specific attributes:

  • Concept: Represents a financial measure or item (e.g., “Assets”) with an associated label and data type.

  • Facts: Actual numerical values associated with the concept, with attributes like “value,” “unitRef,” and “contextRef.”

  • Attributes: Additional attributes providing context for the data, such as reporting period, currency unit, or data precision.

Effectively analyzing this data involves selecting relevant concepts and Fact, potentially transforming or pivoting the data for further processing and visualization.

Understanding the dataset

Let’s start by exploring the structure of company_data:

Show the code
# Visualize structure of the company_data 
str(company_data, max.level = 1) 
List of 3
 $ company_Metadata:List of 22
 $ company_Facts   :List of 3
 $ company_Concept :List of 7

The output reveals that company_data structure comprises three lists with nested lists, such as company_Metadata with 22 lists.

Note
In R, a list is a powerful data structure that can hold elements of different data types. This flexibility allows each element to be unique and cater to specific data requirements. For the company_data object, the list structure plays a crucial role in organizing various pieces of information, including financial data, company descriptions, and filing details. This heterogeneous nature of the data necessitates a flexible data structure like a list to accommodate these diverse data types. Understanding the organization and structure of the company_data list is essential for effective navigation and extraction of specific information. By grasping the relationships between the list elements, users can efficiently retrieve the desired data elements for analysis and interpretation.

To access the lists we use the symbol $ in after the object e.g. company_data$company_Metadata.

Next, we split the company_data into separate lists: company_Metadata, company_Facts, company_Concept.

Show the code
# Split the lists in company_data
company_Metadata <- company_data$company_Metadata
company_Facts <- company_data$company_Facts
company_Concept <- company_data$company_Concept

Now, let’s examine the structures and content of these lists:

Company Metadata

Let’s start with company_Metadata which includes 22 elements: characters, integer, sub-list (or nested list), etc.

Show the code
# Visualize structure of the company_Metadata
str(company_Metadata, max.level = 1)
List of 22
 $ cik                              : chr "1009829"
 $ entityType                       : chr "operating"
 $ sic                              : chr "3944"
 $ sicDescription                   : chr "Games, Toys & Children's Vehicles (No Dolls & Bicycles)"
 $ insiderTransactionForOwnerExists : int 0
 $ insiderTransactionForIssuerExists: int 1
 $ name                             : chr "JAKKS PACIFIC INC"
 $ tickers                          : chr [1:2] "JAKK" "JAKP"
 $ exchanges                        : chr [1:2] "Nasdaq" "OTC"
 $ ein                              : chr "954527222"
 $ description                      : chr ""
 $ website                          : chr ""
 $ investorWebsite                  : chr ""
 $ category                         : chr "Accelerated filer<br>Smaller reporting company"
 $ fiscalYearEnd                    : chr "1231"
 $ stateOfIncorporation             : chr "DE"
 $ stateOfIncorporationDescription  : chr "DE"
 $ addresses                        :List of 2
 $ phone                            : chr "424-268-9444"
 $ flags                            : chr ""
 $ formerNames                      : list()
 $ filings                          :List of 2

For our purpose, the most relevant information of company_Metadata are:

  1. cik, as described above.
  2. sic, standard industrial classification. The SIC codes were used to classify companies into specific industry segments based on their primary business activities. Each four-digit SIC code represented a different industry or sector.
  3. sicDescription the description of the standard industrial classification
  4. name, name of the company
  5. tickers, identifier a publicly traded company’s stock on a particular stock market
  6. filing which includes the filing attributes.

Here the structure of company_Metadata:

Show the code
# Visualize structure of the company_Metadata
str(company_Metadata$filing, max.level = 2)
List of 2
 $ recent:List of 14
  ..$ accessionNumber      : chr [1:1003] "0001185185-24-000477" "0001185185-24-000433" "9999999995-24-000892" "0001185185-24-000367" ...
  ..$ filingDate           : chr [1:1003] "2024-05-08" "2024-04-25" "2024-04-08" "2024-04-08" ...
  ..$ reportDate           : chr [1:1003] "2024-03-31" "2024-04-24" "" "2024-03-29" ...
  ..$ acceptanceDateTime   : chr [1:1003] "2024-05-08T08:20:35.000Z" "2024-04-25T15:35:51.000Z" "2024-04-09T00:15:13.000Z" "2024-04-08T17:15:44.000Z" ...
  ..$ act                  : chr [1:1003] "34" "34" "33" "34" ...
  ..$ form                 : chr [1:1003] "10-Q" "8-K" "EFFECT" "8-K" ...
  ..$ fileNumber           : chr [1:1003] "001-35448" "001-35448" "333-278220" "001-35448" ...
  ..$ filmNumber           : chr [1:1003] "24924366" "24875827" "24831031" "24830448" ...
  ..$ items                : chr [1:1003] "" "2.02,9.01" "S-3,,2024-04-08 16:15:00" "5.02" ...
  ..$ size                 : int [1:1003] 5719341 656430 1732 176775 7831 9913 190682 43835 220773 11376283 ...
  ..$ isXBRL               : int [1:1003] 1 1 0 1 0 0 0 0 0 1 ...
  ..$ isInlineXBRL         : int [1:1003] 1 1 0 1 0 0 0 0 0 1 ...
  ..$ primaryDocument      : chr [1:1003] "jakkspacif20240331_10q.htm" "jakkspacif20240424_8k.htm" "xslEFFECTX01/primary_doc.xml" "jakkspacif20240408_8k.htm" ...
  ..$ primaryDocDescription: chr [1:1003] "FORM 10-Q" "FORM 8-K" "" "FORM 8-K" ...
 $ files :'data.frame': 1 obs. of  4 variables:
  ..$ name       : chr "CIK0001009829-submissions-001.json"
  ..$ filingCount: int 140
  ..$ filingFrom : chr "1996-06-07"
  ..$ filingTo   : chr "2003-07-02"

The format of the dataset as printed is not very useful. We see that there are useful information on the forms (e.g. 10K) and dates (e.g. filing dates).

For now we will keep it as is and we will come back later on how to improve the readability

Company Facts

company_Facts is relatively simple and is a list of 3 elements.

Show the code
# Visualize structure of the company_Facts
str(company_Facts, max.level = 1)
List of 3
 $ cik       : int 1009829
 $ entityName: chr "JAKKS Pacific, Inc."
 $ facts     :List of 2

For our purpose, the last element company_Facts$facts is the most relevant one.

Show the code
# Visualize structure of the company_Facts
str(company_Facts$facts, max.level = 1)
List of 2
 $ dei    :List of 2
 $ us-gaap:List of 508

The us-gaap list includes relevant Facts, containing 487 nested elements. Let’s examine the first five.

Show the code
# Visualize structure of the company_Facts
Facts_us_gaap <- str(company_Facts$facts$`us-gaap`[1:5], max.level = 1)
List of 5
 $ AccountsPayableCurrent        :List of 3
 $ AccountsReceivableNetCurrent  :List of 3
 $ AccruedAdvertisingCurrent     :List of 3
 $ AccruedBonusesCurrent         :List of 3
 $ AccruedEmployeeBenefitsCurrent:List of 3

These elements, to which we will refer as us_gaap_reference, include essential fundamentals of the company and are themselves nested lists. Let’s explore the structure of the first one.

Show the code
# Visualize structure of the company_Facts
str(company_Facts$facts$`us-gaap`[1], max.level = 4)
List of 1
 $ AccountsPayableCurrent:List of 3
  ..$ label      : chr "Accounts Payable, Current"
  ..$ description: chr "Carrying value as of the balance sheet date of liabilities incurred (and for which invoices have typically been"| __truncated__
  ..$ units      :List of 1
  .. ..$ USD:'data.frame':  106 obs. of  8 variables:
  .. .. ..$ end  : chr [1:106] "2010-12-31" "2010-12-31" "2010-12-31" "2011-06-30" ...
  .. .. ..$ val  : int [1:106] 35886000 35886000 35886000 51537000 85352000 26430000 26430000 26430000 26430000 26430000 ...
  .. .. ..$ accn : chr [1:106] "0001157523-11-004475" "0001157523-11-006668" "0001157523-12-001404" "0001157523-11-004475" ...
  .. .. ..$ fy   : int [1:106] 2011 2011 2011 2011 2011 2011 2012 2012 2012 2012 ...
  .. .. ..$ fp   : chr [1:106] "Q2" "Q3" "FY" "Q2" ...
  .. .. ..$ form : chr [1:106] "10-Q" "10-Q" "10-K" "10-Q" ...
  .. .. ..$ filed: chr [1:106] "2011-08-01" "2011-11-09" "2012-03-15" "2011-08-01" ...
  .. .. ..$ frame: chr [1:106] NA NA "CY2010Q4I" "CY2011Q2I" ...

The output presents the structure of the information related to the first element: AccountsPayable

  • AccountsPayable: Represents a financial concept within the us-gaap section, specifically referring to “Accounts Payable (Deprecated 2009-01-31).”

    • label: This column represents the financial concept or measure, such as “Accounts Payable (Deprecated 2009-01-31).”

    • description: A detailed explanation of the concept, providing insight into the carrying value as of the balance sheet date.

    • units: A data frame with 2 observations and 8 variables. The variables include information such as:

      • end: Indicates the end date of the reporting period associated with the financial data.

      • val: Represents the numerical value associated with the financial concept. It includes the unit of measure (e.g., million - “M”).

      • accn: Stands for accession number, a unique identifier assigned by the SEC to each submission.

      • fy: Represents the fiscal year associated with the financial data

      • fp: Represents the fiscal period (e.g., Q3 for the third quarter, FY for the full fiscal year).

      • form: Indicates the type of form filed with the SEC (e.g., 10-Q for quarterly reports, 10-K for annual reports).

      • filed: Represents the date on which the form was filed with the SEC.

      • frame Provides information about the frame, and in this case, it appears to be a combination of calendar year, fiscal quarter, and an additional identifier. For instance “CY2008Q3I” suggests a possible combination of calendar year (CY), year (2008), fiscal quarter (Q3), and possibly an additional identifier (“I”)

This hierarchical structure provides a detailed view of the financial concept “Accounts Payable (Deprecated 2009-01-31)” within the us-gaap section, including its label, description, and historical data with unit details.


Most of the SEC data required for fundamentals analysis is included in a structure of nested lists. We will see in the next section how to properly retrieve this data.


Company Concept

Finally, let’s examine the structure associated with the company’s Concept.

Show the code
# Visualize structure of the company_Concepts
str(company_Concept, max.level = 3)
List of 7
 $ cik        : int 1009829
 $ taxonomy   : chr "us-gaap"
 $ tag        : chr "Assets"
 $ label      : chr "Assets"
 $ description: chr "Sum of the carrying amounts as of the balance sheet date of all assets that are recognized. Assets are probable"| __truncated__
 $ entityName : chr "JAKKS Pacific, Inc."
 $ units      :List of 1
  ..$ USD:'data.frame': 107 obs. of  8 variables:
  .. ..$ end  : chr [1:107] "2010-12-31" "2010-12-31" "2010-12-31" "2011-06-30" ...
  .. ..$ val  : int [1:107] 633406000 633406000 633406000 614892000 707611000 615234000 615234000 615234000 615234000 615234000 ...
  .. ..$ accn : chr [1:107] "0001157523-11-004475" "0001157523-11-006668" "0001157523-12-001404" "0001157523-11-004475" ...
  .. ..$ fy   : int [1:107] 2011 2011 2011 2011 2011 2011 2012 2012 2012 2012 ...
  .. ..$ fp   : chr [1:107] "Q2" "Q3" "FY" "Q2" ...
  .. ..$ form : chr [1:107] "10-Q" "10-Q" "10-K" "10-Q" ...
  .. ..$ filed: chr [1:107] "2011-08-01" "2011-11-09" "2012-03-15" "2011-08-01" ...
  .. ..$ frame: chr [1:107] NA NA "CY2010Q4I" "CY2011Q2I" ...

The output shows the structure associated with the Asset of the company under the taxonomy of us-gaap.

For the purpose of our analysis, we will use company_Facts which includes also the us_gaap_reference.

Footnotes

  1. The definitions provided on this website are crafted for non-practitioners and may lack the rigor and precision required by experts. For a more thorough understanding of XBRL financial reporting, we recommend referring to XBRL-based structured digital financial reporting where you can find a comprehensive and rigorous explanation. To delve deeper into the subject, we suggest reading the following authoritative texts: Essentials of XBRL-based Digital Financial Reporting and Mastering XBRL-based Digital Financial Reporting by C. Hoffman.↩︎