[R-sig-Geo] [FORGED] Modifying the length of a matrix variable

r@i@1290 m@iii@g oii @im@com r@i@1290 m@iii@g oii @im@com
Sun Mar 31 03:49:58 CEST 2019


SUCCESS! Thank you so, so much, Stephen! Indeed, that worked out well, and dim(subset) shows:
64   128    90
I am very, very grateful for this! Thanks to the others, too, for their assistance with this!

-----Original Message-----
From: Stephen Stewart <stephen.stewart85 using gmail.com>
To: Rolf Turner <r.turner using auckland.ac.nz>
Cc: rain1290 <rain1290 using aim.com>; R-sig-geo Mailing List <r-sig-geo using r-project.org>
Sent: Sat, Mar 30, 2019 8:16 pm
Subject: Re: [R-sig-Geo] [FORGED] Modifying the length of a matrix variable

The last few messages provided important information which was previously absent. Try:

subset = Model4[[1:90]] 

This will subset the brick to layers 1 through 90.

I would also suggest some further reading around the raster package and NetCDF files (e.g. the ncdf4 package) would be useful to you.

On Sun, 31 Mar 2019 at 11:06, Rolf Turner <r.turner using auckland.ac.nz> wrote:


On 31/03/19 12:56 PM, rain1290 using aim.com wrote:

> Model4 <- brick("MaxPrecCCCMACanESM2rcp45.nc", var="onedaymax")
> 
> 
> That is how Model4 is derived.
> 
> When trying class(Model4), I receive:
> 
> [1] "RasterBrick" attr(,"package") [1] "raster"
> 
> **//___^
> 
> Meanwhile, I will check on Google to see what I come up with in terms of 
> your suggestion. :)

I know nothing about rasters, the brick() function, or the raster 
package, so include me out at this stage.

Others on the list may be able to help you.  Particular if you can force 
yourself to ask a *focussed* question.

cheers,

Rolf

-- 
Honorary Research Fellow
Department of Statistics
University of Auckland
Phone: +64-9-373-7599 ext. 88276

_______________________________________________
R-sig-Geo mailing list
R-sig-Geo using r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-geo


	[[alternative HTML version deleted]]



More information about the R-sig-Geo mailing list