Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
71 views
in Technique[技术] by (71.8m points)

R - Netcdf File collapse a dimension

I'm trying to work with netcdf files (ERA5) in R and just wish to check is there a neat way to collapse a dimension? Dimension is expver.

The dimension/size of my dataset is say: 25 19 2 8784 (i.e. Jan - Dec for a specific grid size of 25x19)

Data can be found within:

25 19 1 1:7320 (i.e. Jan - Oct)

25 19 2 7321: 8784 (i.e. Nov - Dec).

NA can be found within:

25 19 1 7320:8784 (i.e. Nov -Dec)

25 19 2 1:7321 (i.e. Jan - Oct)

What is the best way of merging this data so that the remaining dataset looks like:

25 19 1 8784 (i.e. removing all NA).

Thanks for any assistance.

Trisha

question from:https://stackoverflow.com/questions/65934449/r-netcdf-file-collapse-a-dimension

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...