Skip to content

Comments

add chunk_details_description#1223

Open
russellhz wants to merge 1 commit intodevelopfrom
all_chunk_info
Open

add chunk_details_description#1223
russellhz wants to merge 1 commit intodevelopfrom
all_chunk_info

Conversation

@russellhz
Copy link
Collaborator

@hassaniazi
New function to get the details and description for a single chunk.

To get the full data system info, users can run:

chunk_names <- find_chunks('^module_[a-zA-Z\\.]*_L.*$')
lapply(chunk_names$name, chunk_details_description) %>% bind_rows()

Still need to address missing details/description for the following chunk:
image

@codecov
Copy link

codecov bot commented Oct 26, 2022

Codecov Report

Merging #1223 (335bffd) into develop (dd2447e) will decrease coverage by 0.05%.
The diff coverage is 67.69%.

@@             Coverage Diff             @@
##           develop    #1223      +/-   ##
===========================================
- Coverage    97.07%   97.02%   -0.06%     
===========================================
  Files          429      429              
  Lines        69407    69415       +8     
===========================================
- Hits         67380    67352      -28     
- Misses        2027     2063      +36     
Impacted Files Coverage Δ
R/utils.R 79.27% <0.00%> (-11.95%) ⬇️
R/zchunk_L102.nonco2_ceds_R_S_Y.R 30.32% <0.00%> (ø)
R/zchunk_LA100.IEA_downscale_ctry.R 17.61% <0.00%> (ø)
R/zchunk_L224.heat.R 89.32% <76.47%> (-0.12%) ⬇️
R/driver.R 72.00% <100.00%> (ø)
R/zchunk_L210.resources.R 99.84% <100.00%> (ø)
R/zchunk_L223.electricity.R 94.89% <100.00%> (ø)
R/zchunk_L2233.electricity_water.R 99.88% <100.00%> (ø)
R/zchunk_L2321.cement_USA.R 99.71% <100.00%> (ø)
R/zchunk_L2324.Off_road.R 94.60% <100.00%> (ø)
... and 11 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@hassaniazi
Copy link
Member

I think it's a great idea to have it as single utility function, which gives users the ability to extract introductory information of a chunk. However, info("data_object") can also do something similar. Although yes, not for chunks, but for individual chunks one can easily find details and description in the chunk header by simply scrolling up.
The motivation behind this is to give an overarching summary of data system at one place, which can be handy for starters, or during debugging, or even setting scenarios. So, I think it could be equally great to have it run on full data system and return a file gcamdata_chunks_info in data/ folder

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants