Prajjwal.
I have been working on some functionality for that but this is currently
not operational. What you can do is create a stack for the two bricks (one
for each time period); or vice-versa to get all values accessible in a
single object. However, it is probably easier to work with separate bricks
for each time period (or level).
Robert

On Tue, Jan 8, 2013 at 8:42 AM, ppanday <ppanday@clarku.edu> wrote:

> Hello all
>
> I have a netCDF file with 42 levels across time. Is it possible to load
> using brick or stack both levels and time dimensions? Using brick option, I
> can only load either all time or all levels? Is it possible to work with
> both dimensions so that if I need to average across levels, across time, I
> would be able to do that.
>
> Thanks,
> Prajjwal
>
> **********************************************************************
> Example: foo.nc
> [1] "file foo.nc has 4 dimensions:"
> [1] "time   Size: 2"
> [1] "levels   Size: 42"
> [1] "longitude   Size: 540"
> [1] "latitude   Size: 361"
> [1] "------------------------"
> [1] "file foo.nc has 1 variables:"
> [1] "float t[longitude,latitude,levels,time]  Longname:Air temperature
> Missval:999999986991104"
>
> r <- brick("foo.nc")
> r
> class       : RasterBrick
> dimensions  : 361, 540, 194940, 2  (nrow, ncol, ncell, nlayers)
> resolution  : 0.6666667, 0.5  (x, y)
> extent      : -180.3333, 179.6667, -90.25, 90.25  (xmin, xmax, ymin, ymax)
> coord. ref. : +proj=longlat +datum=WGS84
> data source : C:\Data\Documents\IBIS\reanalysis_data\merra\temp\foo.nc
> names       : X0, X720
> z-value     : 0, 720
> varname     : t
> level       : 1
>
>
>
>
>
> --
> View this message in context:
> http://r-sig-geo.2731867.n2.nabble.com/loading-all-levels-and-time-in-netCDF-using-brick-stack-tp7582269.html
> Sent from the R-sig-geo mailing list archive at Nabble.com.
>
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo@r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>

	[[alternative HTML version deleted]]

