myAges <- Ages(MaxAge=20)11 Ages
The S4 object class ages contains information related to the age classes of a Stock object.
New Ages objects are created with the Ages() function, which has one required argument MaxAge that specifies the value of the maximum age class:
Units(myAges)[1] "year"
Note that MaxAge is set in time units of quarter. It is important that the time units in the Ages object matches the number of seasons in the OM.
Also note that, following the convention in Years(OM) the age classes are always in units of year:
To keep things simple, we’ll change our OM back to annual time-steps and re-recreate the Ages object accordingly:
