It should be possible to create a RasterStack (preferred) or RasterBrick
from a list of RasterLayer objects

library(raster)
r <- raster(nc=5, nr=5)
r[] <- 1:25
x <- list(r, r, r)
s <- stack(x)
# or b <- brick(x)
# or b <- brick(s)

however, I understand Gianni's objective to be to get the extent of each
RasterLayer, and that these extents different for each layer, such that you
cannot make a RasterStack/Brick.

perhaps what you are after is


fileNames <- Sys.glob("*.asc")
e <- sapply(fileNames, function(x) extent(raster(x) ) )


# or something like
e <- t (sapply(fileNames, function(x) as.vector(t(bbox(extent(raster(x) )
)))) )

Robert

On Tue, Feb 14, 2012 at 10:04 AM, etiennebr <etiennebr@gmail.com> wrote:

> 2012/2/14 gianni lavaredo [via R-sig-geo] <
> ml-node+s2731867n7284084h32@n2.nabble.com>
>
> > Dear Etienne,
> >
> > i hale always the some error
> >
> > b <- brick(my.Area.tot)
> > Error in function (classes, fdef, mtable)  :
> >   unable to find an inherited method for function "brick", for signature
> > "list"
> >
> Hmmm... do you have a the latest raster package ? I can read lists with
> brick.
>
> Maybe Robert will be able to help on this one.
>
> Otherwise, could you provide a reproducible example ?
>
> Etienne
>
>
> --
> View this message in context:
> http://r-sig-geo.2731867.n2.nabble.com/help-to-create-a-raster-BRICK-from-a-list-tp7266815p7284910.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]]

