-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10 from gp1981/standardized_report_enhanced
Standardized Balancesheet Function
- Loading branch information
Showing
10 changed files
with
215 additions
and
115 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,3 @@ | ||
# Author: gp1981 | ||
# Purpose: Contains the script for processing, analyzing, and visualizing SEC data. | ||
# Disclaimer: This script is intended for educational purposes only and should not be used for investment decisions. Use at your own risk. | ||
|
||
# Function to unnest list company_Facts ---------------------------------- | ||
|
||
# Un-nest the company_Facts (and nested unit list) | ||
FactsList_to_Dataframe <- function(company_Facts_us_gaap) { | ||
df_Facts <- company_Facts_us_gaap %>% | ||
tibble() %>% | ||
unnest_wider(col = everything()) %>% | ||
unnest(cols = c(units)) %>% | ||
unnest(cols = c(units)) | ||
|
||
df_Facts <- as.data.frame(df_Facts) | ||
|
||
# Mutate to reduce values in millions by dividing by 1 million | ||
df_Facts <- df_Facts %>% | ||
mutate(val = val / 1e6) | ||
|
||
return(df_Facts) | ||
} | ||
|
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
# R script: Main Script | ||
# Appendix A1: R Main script | ||
|
||
Work in progress [..] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
# R script: Functions | ||
# Appendix A2: R script functions | ||
|
||
Work in progress [..] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters