function [data, auxData, metaData, txtData, weights] = mydata_Mercenaria_mercenaria

%% set metaData
metaData.phylum     = 'Mollusca';
metaData.class      = 'Bivalvia';
metaData.order      = 'Venerida';
metaData.family     = 'Veneridae';
metaData.species    = 'Mercenaria_mercenaria';
metaData.species_en = 'Hard clam';

metaData.ecoCode.climate = {'MA', 'MB', 'MC'};
metaData.ecoCode.ecozone = {'MAW'};
metaData.ecoCode.habitat = {'0jMp', 'jiMb'};
metaData.ecoCode.embryo  = {'Mp'};
metaData.ecoCode.migrate = {};
metaData.ecoCode.food    = {'biPp'};
metaData.ecoCode.gender  = {'D'};
metaData.ecoCode.reprod  = {'O'};

metaData.T_typical  = C2K(15); % K, body temp
metaData.data_0     = {'ab'; 'aj'; 'ap'; 'am'; 'Lb'; 'Lj'; 'Lp'; 'Li'; 'Wwb'; 'Wdj'; 'Wdp'; 'Wdi'; 'Ri'}; 
metaData.data_1     = {'t-L_f'; 'L-Ww'; 'L-Wd'; 'Wd-JO'};                                                 

metaData.COMPLETE = 3.5; % using criteria of LikaKear2011

metaData.author    = {'Romain Lavaud'};
metaData.date_subm = [2018 01 22];
metaData.email     = {'romain.lavaud@dfo-mpo.gc.ca'};
metaData.address   = {'Postdoc at Fisheries and Oceans Canada'};

metaData.curator     = {'Bas Kooijman'};
metaData.email_cur   = {'bas.kooijman@vu.nl'}; 
metaData.date_acc    = [2018 01 23]; 

%% set data
% zero-variate data;

data.ab   = 0.75;      units.ab      = 'd';   label.ab      = 'age at birth';                     bibkey.ab = 'KraeCast2001';
  temp.ab = C2K(20);   units.temp.ab = 'K';   label.temp.ab = 'temperature';
data.aj   = 15;        units.aj      = 'd';   label.aj      = 'age at metamorphosis';             bibkey.aj = {'KraeCast2001','Ever1987'};
  temp.aj = C2K(20);   units.temp.aj = 'K';   label.temp.aj = 'temperature';
data.ap   = 1095;      units.ap      = 'd';   label.ap      = 'age at puberty';                   bibkey.ap = 'Ever1987';
  temp.ap = C2K(15);   units.temp.ap = 'K';   label.temp.ap = 'temperature';
data.am   = 100 * 365; units.am      = 'd';   label.am      = 'life span';                        bibkey.am = 'RigwRich2011';
  temp.am = C2K(15);   units.temp.am = 'K';   label.temp.am = 'temperature';

data.Lb   = 0.008;     units.Lb      = 'cm';  label.Lb      = 'diameter of a D-larvae';           bibkey.Lb  = 'KraeCast2001';
data.Lj   = 0.025;     units.Lj      = 'cm';  label.Lj      = 'diameter of a pediveliger larvae'; bibkey.Lj  = 'KraeCast2001';
data.Lp   = 3;         units.Lp      = 'cm';  label.Lp      = 'shell length';                     bibkey.Lp  = 'KraeCast2001';
data.Li   = 11;      units.Li      = 'cm';  label.Li      = 'ultimate shell length';            bibkey.Li  = 'RigwRich2011';

data.Wwb  = 2.2e-8;      units.Wwb     = 'g';   label.Wwb     = 'wet weight at birth';            bibkey.Wwb = 'KraeCast1982';
  comment.Wwb = 'based on egg diameter of 35 mum: pi/6*0.0035^3';
data.Wdj  = 7.5e-6;    units.Wdj     = 'g';   label.Wdj     = 'dry weight at metamorphosis';      bibkey.Wdj = 'LabaFern1999';
  comment.Wdj = 'Data on Ostrea edulis';
data.Wdp  = 0.25;       units.Wdp     = 'g';   label.Wdp     = 'dry weight at puberty';           bibkey.Wdp = {'KraeCast2001','HofmKlin2006'};
  comment.Wdp = 'based on Wdp = (Lp/Li)^3 * Wdi';
data.Wdi  = 12.3;       units.Wdi     = 'g';   label.Wdi     = 'ultimate dry weight';               bibkey.Wdi = 'HofmKlin2006';

data.Ri   = 39.5e6/365;  units.Ri    = '#/d'; label.Ri      = 'maximum reprod rate';              bibkey.Ri  = {'Ever1987','Anse1967'};
  temp.Ri = C2K(15);   units.temp.Ri = 'K';   label.temp.Ri = 'temperature';
  
% uni-variate data
  % Data from RigwRich2011 - Field monitoring (Massachusetts)
  % time (d) vs shell length (cm) at f = 0.7 (unknown)
data.tL_RigwRich2011 = [383 416 734 1146 1179 1464 1497 1847 1847 2164 2259 2610 2639 2957 2960 3307 3340 3654 3657 3690 4004 4037 4070 4417 4420 4482 4734 4767 4796 5084 5147 5209 5497 5526 5877 5909 6227 6289 6544 6607 6986 6986 7337 7399 7654 7716 8063 8067 8446 8479 8793 8793 9176 9205 9523 9523 9873 10220 10665 10983 13173 13487 17542 18973 19382 20805 20842 21882 22641 22677 25181 26638 27744 29233 30280 31072 31770 32850 32879 33576; % d, time since birth
                        1.59 1.27 2.15 2.70 2.52 3.42 3.10 3.47 4.19 4.61 3.82 4.35 4.80 4.51 5.22 4.56 5.33 4.66 5.49 6.04 5.64 4.96 6.23 5.17 6.41 5.75 6.52 5.88 5.59 6.63 6.09 5.78 6.81 6.23 7.13 6.49 7.21 6.68 7.34 6.78 6.92 7.42 7.52 7.13 7.29 7.74 7.42 7.79 7.58 7.79 7.66 7.84 7.82 8 8.05 8.21 8.27 8.37 8.56 8.82 9.83 10.01 9.61 10.86 9.82 9 11.52 8.79 8.71 10.43 10.11 10 9.63 9.63 10.03 9.2 9.39 10.71 10.18 9.79]'; % cm, shell length
units.tL_RigwRich2011      = {'d', 'cm'}; label.tL_RigwRich2011      = {'time since birth', 'shell length'};
temp.tL_RigwRich2011       = C2K(15);     bibkey.tL_RigwRich2011     = 'RigwRich2011';
units.temp.tL_RigwRich2011 = 'K';         label.temp.tL_RigwRich2011 = 'temperature';

 % Data from RiceHick1989 - Field monitoring (South Atlantic)
 % time (d) vs shell length (cm) at f = 0.8 (unknown)
data.tL_RiceHick1989 = [593 596 614 628 628 630 993 995 1009 1010 1011 1358 1358 1375 1376 1425 1742 1757 1758 1791 2142 2156 2156 2157 2157 2157 2158 2159 2172 2489 2490 2491 2506 2523 2890 2904 2905 2905 2905 2906 2906 3236 3238 3239 3241 3255 3255 3258 3586 3586 3587 3589 3604 3604 3604 3605 3953 3972 3987 3988 3988 4020 4303 4335 4337 4352 4352 4353 4700 4703 4720 4720 4803 5067 5070 5085 5433 5434 5435 5451 5453 5470 5800 5818 5834 6152 6169 6551 6551 7298 7665 7681 7683 9197 11731 12109 12114 12495; % d, time since birth
                        4.26 2.12 1.55 3.25 3.22 1.81 4.2 2.94 4.55 3.91 3.56 5.16 4.88 4.57 4.04 4.53 4.77 5.36 5.14 5.05 4.63 6.29 5.84 5.69 5.51 5.1 4.87 4.41 6.22 6.4 5.78 4.83 6.24 5.71 5.16 6.77 6.53 6.35 6.17 5.93 5.65 8.01 6.62 5.58 4.65 6.28 5.95 4.34 7.81 7.56 7.25 5.95 7.01 6.77 6.59 6.22 7.21 5.54 6.75 6.48 6.02 7.12 7.28 8.18 6.7 7.8 7.67 7.17 8.77 7.07 6.81 6.55 7.07 8.51 6.75 7.61 8.68 8.07 7.51 7.91 6.81 6.65 8.27 7.67 8.13 7.1 6.79 7.8 7.27 9.03 8.94 9.14 8.19 8.79 7.53 11.08 7.75 8.87]'; % cm, shell length at ftL3 and TtL3
units.tL_RiceHick1989      = {'d', 'cm'}; label.tL_RiceHick1989      = {'time since birth', 'shell length'};
temp.tL_RiceHick1989       = C2K(20);     bibkey.tL_RiceHick1989     = 'RiceHick1989';
units.temp.tL_RiceHick1989 = 'K';         label.temp.tL_RiceHick1989 = 'temperature';
 % shell length (cm) vs wet weight (g)
data.LWw_RiceHick1989 = [2.95 2.75 3.63 4.37 3.89 4.47 5.01 5.13 5.13 5.37 5.89 5.62 5.75 6.03 5.5 5.75 5.89 7.08 6.92 7.24 6.03 6.61 6.61 7.59 7.08 7.41 7.41 6.92 7.59 7.94 7.08 7.76 8.13 8.91 8.71 8.51 9.12 8.91 9.33 9.55; % cm, shell length
                         0.6 0.89 2.51 2.63 3.02 4.17 5.37 6.31 6.92 7.41 8.51 8.71 8.71 8.71 9.12 9.12 10 10.47 10.72 11.22 11.48 12.02 12.59 14.13 14.79 15.49 15.85 17.38 18.62 19.95 20.89 20.89 23.44 25.12 26.3 29.51 29.51 33.88 37.15 37.15]'; % g, wet weight
units.LWw_RiceHick1989 = {'cm', 'g'}; label.LWw_RiceHick1989 = {'shell length', 'wet weight'}; bibkey.LWw_RiceHick1989 = 'RiceHick1989';

  % Data from CharShri2004 - Field monitoring (Massachusetts)
  % shell length (cm) vs dry weight (g) at f = 0.7 (unknown)
data.LWd_CharShri2004 = [1.05 2.11 2.18 2.21 2.51 2.64 2.86 3.04 3.06 3.29 3.39 3.52 3.54 3.74 3.79 3.89 4.15 4.25 4.27 4.32 4.35 4.5 4.57 4.7 4.72 4.83 4.85 4.85 5.08 5.08 5.13 5.3 5.4 5.43 5.43 5.45 5.71 5.78 5.83 5.83 5.93 5.98 6.03 6.08 6.23 6.26 6.36 6.39 6.41 6.44 6.49 6.56 6.61 6.76 6.86 6.91 6.94 7.01 7.04 7.09 7.09 7.14 7.14 7.22 7.24 7.32 7.42 7.42 7.44 7.59 7.67 7.72 7.74 7.82 7.87 7.9 8 8.05 8.1 8.1 8.15 8.22 8.27 8.32 8.32 8.37 8.4 8.45 8.47 8.6 8.63 8.68 8.73 8.8 8.83 8.88 8.9 8.93 8.98 8.98 9.15 9.28 9.38 9.71 9.78 10.97 12.27; % cm, shell length
                         0.09 0.04 0.24 0.12 0.16 0.16 0.16 0.12 0.12 0.18 0.36 0.42 0.18 0.07 0.3 0.23 0.45 0.3 0.54 0.5 0.68 0.64 0.35 0.8 0.73 0.85 0.8 0.5 0.88 1.04 0.52 0.85 1.16 1.02 0.66 1.02 0.8 1.36 1.66 0.99 0.66 2.19 1.19 0.94 0.87 2.34 1.02 1.52 2.29 1.38 1.19 2.16 2.33 2.09 2.48 1.92 1.71 2.45 1.74 2.07 2.36 3.5 1.28 2.26 1.4 2.9 4.56 1.68 2.48 3 2.19 3.1 2.72 3.1 2.6 3.57 3.48 2.71 3.09 2.36 4.29 4.72 2.76 2.24 3.69 2.62 3.48 4.13 3 5.15 4.6 3.28 5.39 4.22 3.83 3.91 3.81 5.48 5.32 2.98 5.79 5.06 5.03 5.43 4.53 8.52 9.6]'; % g, dry weight
units.LWd_CharShri2004 = {'cm', 'g'}; label.LWd_CharShri2004 = {'shell length', 'dry weight'}; bibkey.LWd_CharShri2004 = 'CharShri2004';

 % Data from BrowHeil2010 - Lab experiment (UK)
 % dry weight (g) vs respiration (mlO2/h) at f = 0
data.WdJO_BrowHeil2010 = [0.014 0.025 0.03 0.059 0.17 0.249 0.304 0.933 1.625 1.7 1.888 2.184 2.402 2.475 2.875 3.921 4.355 8.818; % g, dry weight
                          0.065 0.095 0.066 0.119 0.096 0.23 0.205 0.382 0.455 0.419 0.47 0.796 0.796 0.911 0.883 1.269 1.295 2.618]'; % mlO2/h, respiration
units.WdJO_BrowHeil2010      = {'g', 'ml/h'}; label.WdJO_BrowHeil2010      = {'dry weight', 'Oxygen consumption'};
temp.WdJO_BrowHeil2010       = C2K(19.5);       bibkey.WdJO_BrowHeil2010     = 'BrowHeil2010';
units.temp.WdJO_BrowHeil2010 = 'K';             label.temp.WdJO_BrowHeil2010 = 'temperature';


%% set weights
weights    = setweights(data, []);
weights.tL_RigwRich2011 = 50 * weights.tL_RigwRich2011;
weights.tL_RiceHick1989 = 5 * weights.tL_RiceHick1989;
weights.Lb = 0;
weights.Lj = 0;

 % set pseudodata and respective weights
[data, units, label, weights] = addpseudodata(data, units, label, weights);
weights.psd.k_J = 0; weights.psd.k = 0.1;
data.psd.k = 0.3; units.psd.k  = '-'; label.psd.k  = 'maintenance ratio'; 
weights.psd.p_M = 10 * weights.psd.p_M;

%% pack auxData and txtData for output
auxData.temp   = temp;
txtData.units  = units;
txtData.label  = label;
txtData.bibkey = bibkey;
txtData.comment = comment;

%% Links
metaData.links.id_CoL = '3ZTFD'; % Cat of Life
metaData.links.id_ITIS = '714654'; % ITIS
metaData.links.id_EoL = '46469524'; % Ency of Life
metaData.links.id_Wiki = 'Mercenaria_mercenaria'; % Wikipedia
metaData.links.id_ADW = 'Mercenaria_mercenaria'; % ADW
metaData.links.id_Taxo = '39696'; % Taxonomicon
metaData.links.id_WoRMS = '141919'; % WoRMS
metaData.links.id_molluscabase = '141919'; % molluscabase


%% References
bibkey = 'Kooy2010'; type = 'Book'; bib = [ ...  % used in setting of chemical parameters and pseudodata
'author = {Kooijman, S.A.L.M.}, ' ...
'year = {2010}, ' ...
'title  = {Dynamic Energy Budget theory for metabolic organisation}, ' ...
'publisher = {Cambridge Univ. Press, Cambridge}, ' ...
'pages = {Table 4.2 (page 150), 8.1 (page 300)}, ' ...
'howpublished = {\url{../../../bib/Kooy2010.html}}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
% 
bibkey = 'KraeCast2001'; type = 'Book'; bib = [ ...
'author = {Kraeuter, J. N. and Castagna, M.}, ' ...
'year = {2001}, ' ...
'title = {Biology of the hard clam}, ' ...
'publisher = {Gulf Professional Publishing (Vol. 31)}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
%
bibkey = 'BrowHeil2010'; type = 'Article'; bib = [ ...
'author = {Brown, A. and Heilmayer, O. and Thatje, S.}, ' ...
'year = {2010}, ' ...
'title = {Metabolic rate and growth in the temperate bivalve \emph{Mercenaria mercenaria} at a biogeographical limit, from the {E}nglish {C}hannel}, ' ...
'journal = {Journal of the Marine Biological Association of the United Kingdom}, ' ...
'volume = {90}, ' ...
'number = {5}, ' ...
'pages = {1019--1023}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
%
bibkey = 'CharShri2004'; type = 'Article'; bib = [ ...
'author = {Carmichael, R. H. and Shriver, A. C. and Valiela, I.}, ' ...
'year = {2004}, ' ...
'title = {Changes in shell and soft tissue growth, tissue composition, and survival of quahogs, \emph{Mercenaria mercenaria}, and softshell clams, \emph{Mya arenaria}, in response to eutrophic-driven changes in food supply and habitat}, ' ...
'journal = {Journal of Experimental Marine Biology and Ecology}, ' ...
'volume = {313}, ' ...
'number = {1}, ' ...
'pages = {75--104}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
%
bibkey = 'Ever1987'; type = 'Article'; bib = [ ...
'author = {Eversole, A. G.}, ' ...
'year = {1987}, ' ...
'title = {Species Profiles: {L}ife Histories and Environmental Requirements of Coastal Fishes and Invertebrates ({S}outh {A}tlantic) Hard Clam}, ' ...
'journal = {Biological report}, ' ...
'volume = {82(11.75)}, ' ...
'pages = {1--33}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
%
bibkey = 'LabaFern1999'; type = 'Article'; bib = [ ...
'author = {Labarta, U. and Fern\`{a}ndez-Reiriz, M. J. and P\''{e}rez-Camacho, A.}, ' ...
'year = {1999}, ' ...
'title = {Energy, biochemical substrates and growth in the larval development, metamorphosis and postlarvae of \emph{Ostrea edulis} ({L}.)}, ' ...
'journal = {Journal of Experimental Marine Biology and Ecology}, ' ...
'volume = {238}, ' ...
'number = {3}, ' ...
'pages = {225--242}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
%
bibkey = 'RiceHick1989'; type = 'Article'; bib = [ ...
'author = {Rice, M. A. and Hickox, C. and Zehra, I.}, ' ...
'year = {1989}, ' ...
'title = {Effects of intensive fishing effort on the population structure of quahogs, \emph{Mercenaria mercenaria} ({L}innaeus, 1758), in {N}arragansett {B}ay}, ' ...
'journal = {Journal of Shellfish Research}, ' ...
'volume = {8}, ' ...
'number = {2}, ' ...
'pages = {345-354}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
%
bibkey = 'RigwRich2011'; type = 'Article'; bib = [ ...
'author = {Rigway, I. D. and Richardson, C. A. and Enos, E. and Ungvari, Z. and Austad, S. N. and Philipp, E. E. R. and Csiszar, A.}, ' ...
'year = {2011}, ' ...
'title = {New species longevity record for the northern quahog (= hard clam), \emph{Mercenaria mercenaria}}, ' ...
'journal = {Journal of Shellfish Research}, ' ...
'volume = {30}, ' ...
'number = {1}, ' ...
'pages = {35--38}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
%
bibkey = 'KraeCast1982'; type = 'Article'; bib = [ ...
'author = {J. N. Kraeuter and M. Castacna and R. van Dessel}, ' ...
'year = {1982}, ' ...
'title = {EGG SIZE AND LARVAL SURVIVAL OF \emph{Mercenaria Mercenaria} ({L}.) AND \emph{Argopecten irradzans} ({L}amarck)}, ' ...
'journal = {J. exp. mar. Biol. Ecol.}, ' ...
'volume = {56}, ' ...
'number = {1}, ' ...
'pages = {3--8}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
%
bibkey = 'Anse1967'; type = 'Article'; bib = [ ...
'author = {A. D. Ansell}, ' ...
'year = {1967}, ' ...
'title = {Egg production of \emph{Mercenaria mercenaria}}, ' ...
'howpublished = {url{onlinelibrary.wiley.com/doi/10.4319/lo.1967.12.1.0172/pdf}}, ' ...
'journal = {Limnol. Oneanogr.}, ' ...
'volume = {12}, ' ...
'pages = {172--176}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];
%
bibkey = 'HofmKlin2006'; type = 'Article'; bib = [ ...
'author = {Hofmann, E. E. and Klinck, J. M. and Kraeuter, J. N. and Powell, E.}, ' ...
'year = {2006}, ' ...
'title = {Population Dynamics Model of the Hard Clam, \emph{Mercenaria Mercenaria}: {D}evelopment of the Age-and Length-Frequency Structure of the Population}, ' ...
'howpublished = {url{https://pdfs.semanticscholar.org/216d/e1b74c9e680a13d9a63a91ca9008c765ccba.pdf}}, ' ...
'journal = {Journal of Shellfish Research}, ' ...
'volume = {25}, ' ...
'number = {2}, ' ...
'pages = {417-444}'];
metaData.biblist.(bibkey) = ['''@', type, '{', bibkey, ', ' bib, '}'';'];

