Forums

Back

Maturity output to calculate SSB

KJ
Kelli Johnson, modified 4 Years ago.

Maturity output to calculate SSB

Youngling Posts: 28 Join Date: 6/13/17 Recent Posts

From Iago Mosqueira: 

I am trying to understand the maturity output in SS_output and how to convert it into the measure that allows me to compute SSB correctly and feed the SR model the right input. For IOTC ALB I have maturity option 3, a vector of values going close to 1, which I extracted from out$endgrowth$Mat_numbers. Following what Kelli and I tried in Lisbon, I moved to using `Mat*Fecund` / Wt_Beg so the vector contained the fecundity used for sablefish. But now this breaks ALB. Is there, or can you create easily enough, give some explanation of what each relevant column in endgrowth (Len_Mat, Age_Mat,  Mat*Fecund, Mat_Bio and Mat_Numbers) mean and if this changes, and how, for each maturity option? Can I know which maturity option was used by looking only at SS_output?

Reply from Kelli Johnson:

I am posting this issue for Iago and giving a half-response. Maybe someone else has an idea while I dig into it further.  The report file only deals with the maturity option in that it provides different output to the "endgrowth" if Maturity_Option <= 2 else Maturity_Option < 5. The report file doesn't actually print out what the maturity option was. I am not familiar enough with the options to know how they would produce different output to generate our own flags. 

Richard Methot, modified 4 Years ago.

RE: Maturity output to calculate SSB

Youngling Posts: 219 Join Date: 11/24/14 Recent Posts

ALK(ALK_idx,g,a)*mat_len(GP4(g))The obvious best solution is to add the maturity option and fecundity option to the output so you can immediately see what has been used.  I'll get it into 3.30.13.00, which is just starting development.

Above the biology-at-age in report.sso is biology-at-length.  Here you will find:

BIOLOGY 2 43 40 1 N_Used_morphs;_lengths;_ages;_season;_by_season_in_endyr
GP Bin Low Mean_Size Wt_len_F Mat_len Spawn Wt_len_M Fecundity
1 1 10 11 0.00746223 1.67014e-05 1.2463e-07 0.00746223 0.00746223
1 2 12 13 0.0130524 2.75357e-05 3.59408e-07 0.0130524 0.0130524

....

1 42 92 93 9.45767 0.999925 9.45696 9.45767 9.45767
1 43 94 95 10.1558 0.999955 10.1553 10.1558 10.1558
 

based on the code:

      SS2out<<gp<<" "<<z<<" "<<len_bins(z)<<" "<<len_bins_m(z)<<" "<<wt_len(1,gp,z)<<" "<<mat_len(gp,z)<<" "<<mat_fec_len(gp,z);
      if(gender==2) {SS2out<<" "<<wt_len(1,N_GP+gp,z);}
      SS2out<<" "<<fec_len(gp,z)<<endl;
where:  len_bins(z) is lower edge of length bin

len_bins_m(z) is middle length of the bin

wt_len(1,gp,z) is female wt at mid-length in season 1.

mat_len is female fraction mature

mat_fec_len is female maturity*fecundity

wt_len_M is body weight at mid-length for males

fec_len is fecundity at length, so fec_len/wt_len is weight-specific fecundity

 

Regarding the biology-at-age quantities:  Len_Mat, Age_Mat,  Mat*Fecund, Mat_Bio and Mat_Numbers

where:

Len_Mat is the length based maturity contribution to age-based maturity:  ALK(ALK_idx,g,a)*mat_len(GP4(g))

Age_Mat is  age based maturity if used:

 if(Maturity_Option<=2)
        {SS2out<<mat_age(GP4(g),a);}
      else if(sx(g)==1 && Maturity_Option<5)
        {SS2out<<Age_Maturity(GP4(g),a);}
      else
        {SS2out<<-1.;}
   

Mat*Fecund displays the contents of fec(a)  and is the age-based quantity that is used throughout SS to calculate spawning biomass (SSB).  So wherever you see spawning biomass reported by SS, it takes fecundity into account so is mature female reproductive output.  With two exceptions:

1.  if you have a one sex model, then SS treats all fish as if they are female.  It does not divide spawning biomass by 2.  You will need to do that yourself if you think it important to do so.

2.  If you use the hermaphroditism option, the male body weight is used to include males in the spawning biomass

Then Mat_Bio and Mat_Numbers are simply the mature female biomass-at-age and numbers-at-age , so ignores fecundity.

 

Hope this helps, we'll try to write it up cleanly and insert into the manual, or write a separate article on "Understanding biology outputs form SS".

Rick

Richard Methot, modified 4 Years ago.

RE: Maturity output to calculate SSB

Youngling Posts: 219 Join Date: 11/24/14 Recent Posts

Code has been added to SS to output natmort, growth, maturity and fecundity options to the definitions section.  It will be released with 3.30.13.

Regarding the sex ratio for one sex models,  SS retains the fraction female parameter in one sex models, but it does not use it for any calculations.  I suggest that in one sex models, SS could multiple the total SSB by the value of the fraction female parameter.  But it would be best to add a switch to SS so users could choose.

So the question is:  add the switch to SS, or add the switch to r4ss?

Rick

Iago Mosqueira, modified 4 Years ago.

RE: Maturity output to calculate SSB

Youngling Posts: 24 Join Date: 8/12/16 Recent Posts

I am now dealing with a different setup and would appreciate some help understanding it. This model has maturity option 5 (disabled) and fecundity option 1, with a=1 and b=0,

                          Num                     Label Value Active_Cnt Phase
Eggs/kg_inter_Fem_GP_1     10    Eggs/kg_inter_Fem_GP_1     1         NA   -99
Eggs/kg_slope_wt_Fem_GP_1  11 Eggs/kg_slope_wt_Fem_GP_1     0         NA   -99

 

endgrowth reports as follows:

 

int_Age  Wt_Beg Wt_Mid Len_Mat Age_Mat Mat*Fecund Mat_F_wtatage Mat_F_Natage
      0   0.024  0.024       1      -1      0.000         0.000        0.000
      1   0.104  0.104       1      -1      0.016         0.016        0.016
      2   0.207  0.207       1      -1      0.157         0.157        0.157
      3   0.304  0.304       1      -1      0.292         0.292        0.292
      4   0.380  0.380       1      -1      0.376         0.376        0.376

 

How is Mat*Fecund being calculated here? They do not match Wt as I expected. How is SSB/SRP being calculated in this case? I am again trying to obtain the same SSB as in derived_quants from abundances and weight at age, and z at age.

Iago Mosqueira, modified 4 Years ago.

RE: Maturity output to calculate SSB

Youngling Posts: 24 Join Date: 8/12/16 Recent Posts

Many thanks. I finally understood that fecundity in this particular model was really maturity by unit weight, so I could correct for it.