├── .gitignore ├── GROA-ForC_integration ├── Duplicates_processing │ ├── ForC.GROA.potential.duplicate.measurement.list.csv │ ├── ForC.GROA.potential.duplicate.sites.list.csv │ └── potential_duplicate_records_working_sheet.csv ├── GROA-ForC mapping │ ├── GROA-ForC variable mapping.csv │ ├── GROA-ForC_measurements_mapping.csv │ ├── GROA-ForC_sites_mapping.csv │ ├── Instructions for populating ForC history table from GROA.docx │ ├── README.md │ └── variable_name_conversion.csv ├── GROA.Rproj ├── Readme.md ├── additional_GROA_files │ ├── ForC and GROA comparison.csv │ ├── ReadMe.md │ └── soiltosurface.csv ├── new_data │ ├── GROA_sites.csv │ ├── new_CITATIONS.csv │ ├── new_ForC_simplified.csv │ ├── new_HISTORY.csv │ ├── new_MEASUREMENTS.csv │ ├── new_PLOTS.csv │ ├── new_SITES.csv │ ├── old_SITES.csv │ └── potential_duplicates │ │ ├── potential.duplicate.records.csv │ │ ├── potential.duplicate.sites.csv │ │ ├── previous_rounds │ │ └── potential.duplicate.records.csv │ │ └── true.duplicate.sites.csv └── scripts │ ├── ID_potential_duplicates_SITES_betweenForC_and_GROA.R │ ├── Importing_GROA_into_ForC_taking_care_of_potential_duplicates.R │ └── archive │ ├── Fill_in_veg_notes_after_the_big_import.R │ └── Importing_GROA_into_ForC.R ├── MappingGlobalCarbon ├── README.md └── gfw_forestlearn │ ├── __init__.py │ ├── convert_hdf_to_raster.py │ ├── fl_regression.py │ └── geo_processing.py ├── README.md ├── data ├── GROA literature.csv ├── METADATA.5.June.2020.docx ├── biomass_litter_CWD.csv ├── sites.csv └── soil.csv └── license.txt /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | .DS_Store 3 | .Rproj.user 4 | .Rhistory 5 | GROA-ForC mapping/~$structions for populating ForC history table from GROA.docx 6 | -------------------------------------------------------------------------------- /GROA-ForC_integration/Duplicates_processing/ForC.GROA.potential.duplicate.measurement.list.csv: -------------------------------------------------------------------------------- 1 | GROA.measurement.ID,is.duplicate.of.ForC.measurement.ID,is.independent.of.ForC.meaurement.ID,double.checked 2 | 4816,15920,,1 3 | 4816,,15921,1 4 | 3003,,7542,1 5 | 3003,,7543,1 6 | 3003,7546,,1 7 | 3003,,7549,1 8 | 3008,7543,,1 9 | 3008,,7546,1 10 | 3008,,7549,1 11 | 5366,11579,,1 12 | 5366,,11580,1 13 | 5366,,11581,1 14 | 5366,,11582,1 15 | 5372,11582,,1 16 | 5372,,11580,1 17 | 5372,,11581,1 18 | 5372,,11579,1 19 | 5378,11563,,1 20 | 5378,,11564,1 21 | 5384,11598,,1 22 | 5384,,11599,1 23 | 5390,11650,,1 24 | 5390,,11651,1 25 | 5396,11623,,1 26 | 5402,11554,,1 27 | 5408,11617,,1 28 | 5414,11527,,1 29 | 5414,,11528,1 30 | 5420,11607,,1 31 | 5426,11512,,1 32 | 5432,11590,,1 33 | 5438,,11563,1 34 | 5438,11564,,1 35 | 5444,,11650,1 36 | 5444,11651,,1 37 | 5450,11545,,1 38 | 5450,,11546,1 39 | 5450,,11547,1 40 | 5450,,11548,1 41 | 5456,11581,,1 42 | 5456,,11579,1 43 | 5456,,11580,1 44 | 5456,,11582,1 45 | 5462,,11579,1 46 | 5462,11580,,1 47 | 5462,,11581,1 48 | 5462,,11582,1 49 | 5468,,11545,1 50 | 5468,11546,,1 51 | 5468,,11547,1 52 | 5468,,11548,1 53 | 5474,11593,,1 54 | 5480,11658,,1 55 | 5480,,11659,1 56 | 5486,11599,,1 57 | 5486,,11598,1 58 | 5492,11547,,1 59 | 5492,,11545,1 60 | 5492,,11546,1 61 | 5492,,11548,1 62 | 5498,11548,,1 63 | 5498,,11545,1 64 | 5498,,11546,1 65 | 5498,,11547,1 66 | 5504,11517,,1 67 | 5510,11659,,1 68 | 5510,,11658,1 69 | 5516,11528,,1 70 | 5516,,11527,1 71 | 5599,12584,,1 72 | 5599,,12583,1 73 | 5730,,16960,1 74 | 4424,,4699,1 75 | 4425,,4700,1 76 | 4432,,4707,1 77 | 4433,,4708,1 78 | 4440,,4683,1 79 | 4441,,4684,1 80 | 4448,,4691,1 81 | 4449,,4692,1 82 | 3283,,11017,1 83 | 1225,9659,,1 84 | 1226,9660,,1 85 | 1227,9661,,1 86 | 1228,9662,,1 87 | 1229,9663,,1 88 | 1230,9664,,1 89 | 1231,9665,,1 90 | 1232,9666,,1 91 | 1233,9667,,1 92 | 1234,9668,,1 93 | 1236,9670,,1 94 | 1237,9671,,1 95 | 1238,9672,,1 96 | 1239,9673,,1 97 | 1148,,10830,1 98 | 1150,,10831,1 99 | 1151,,10834,1 100 | 1154,,10837,1 101 | 1155,,10839,1 102 | 1156,,10839,1 103 | 1157,,10839,1 104 | 1158,,10839,1 105 | 1159,,10840,1 106 | 1160,,10840,1 107 | 1166,,10829,1 108 | 1168,,10831,1 109 | 1169,,10832,1 110 | 1170,,10834,1 111 | 1171,,10834,1 112 | 1172,,10835,1 113 | 1177,,10839,1 114 | 1178,,10839,1 115 | 1179,,10839,1 116 | 1180,,10839,1 117 | 1181,,10842,1 118 | 1182,,10842,1 119 | 1183,,10842,1 120 | 1184,,10842,1 121 | 1185,,10842,1 122 | 1186,,10842,1 123 | 1197,,10843,1 124 | 1198,,10843,1 125 | 1199,,10843,1 126 | 1200,,10844,1 127 | 1200,,10845,1 128 | 1201,,10844,1 129 | 1201,,10845,1 130 | 5663,,9115,1 131 | 5666,,9112,1 132 | 5669,,9109,1 133 | 3004,7547,, 134 | 3452,,14065,1 135 | 3452,14066,,1 136 | 3453,14068,,1 137 | 3453,,14069,1 138 | 3453,,14070,1 139 | 3454,14071,,1 140 | 3455,14073,,1 141 | 3456,14065,,1 142 | 3456,,14066,1 143 | 3457,14067,,1 144 | 3458,14072,,1 145 | 3459,14069,,1 146 | 3459,,14068,1 147 | 3459,,14070,1 148 | 3460,14074,,1 149 | 3460,,14075,1 150 | 3461,14076,,1 151 | 3462,14077,,1 152 | 3462,,14078,1 153 | 3463,14078,,1 154 | 3463,,14077,1 155 | 3464,14070,,1 156 | 3464,,14068,1 157 | 3464,,14069,1 158 | 3465,14075,,1 159 | 3465,,14074,1 160 | 3689,,13431,1 161 | 3691,,13432,1 162 | 3693,,13433,1 163 | 3693,,13436,1 164 | 5724,,16962,1 165 | 3088,,15564,1 166 | 13641,,15566,1 167 | 13642,,15568,1 168 | 13643,,15570,1 169 | 13644,,15572,1 170 | 13273,3354,, 171 | 13281,3399,, 172 | 13283,3409,, 173 | 5013,,8804, 174 | 5015,,8805, 175 | 5017,,8806, 176 | 5019,,8807, 177 | 5369,11611,,1 178 | 2801,7597,, 179 | 2802,7598,, 180 | 2803,7599,, 181 | 2804,7600,, 182 | 2805,7601,, 183 | 2806,7602,, 184 | 2807,7603,, 185 | 2808,7604,, 186 | 2809,7605,, 187 | 2810,7606,, 188 | 2811,7607,, 189 | 2812,7608,, 190 | 2813,7609,, 191 | 2814,7610,, 192 | 2815,7639,, 193 | 9786,7640,, 194 | 9787,7641,, 195 | 9788,7642,, 196 | 9789,7643,, 197 | 9790,7644,, 198 | 9791,7645,, 199 | 9792,7646,, 200 | 14041,16432,, 201 | 14045,16436,, 202 | 14046,16440,, 203 | 14042,16443,, 204 | 14047,16447,, 205 | 14048,16451,, 206 | 14049,16455,, 207 | 14043,16458,, 208 | 14050,16462,, 209 | 14044,16466,, 210 | 14051,16470,, 211 | 5810,16433,, 212 | 5834,16437,, 213 | 5822,16444,, 214 | 5858,16448,, 215 | 5840,16452,, 216 | 5804,16459,, 217 | 5846,16463,, 218 | 5828,16467,, 219 | 5811,16431,, 220 | 5805,16435,, 221 | 5829,16439,, 222 | 5847,16442,, 223 | 5817,16446,, 224 | 5853,16450,, 225 | 5835,16454,, 226 | 5793,16457,, 227 | 5799,16461,, 228 | 5841,16465,, 229 | 5823,16469,, 230 | 35238,12583,, 231 | 35239,12591,, 232 | 35240,12595,, 233 | 35241,12585,, 234 | 35242,12587,, 235 | 35243,12589,, 236 | 35244,12593,, -------------------------------------------------------------------------------- /GROA-ForC_integration/Duplicates_processing/ForC.GROA.potential.duplicate.sites.list.csv: -------------------------------------------------------------------------------- 1 | GROA.site.ID,is.duplicate.of.ForC.site.ID,is.independent.of.ForC.site.ID 2 | 3821,862,NA 3 | 286,596,NA 4 | 3577,NA,1555 5 | 295,87,NA 6 | 294,1324,NA 7 | 293,563,NA 8 | 40,NA,1333 9 | 2403,NA,526 10 | 314,1168,NA 11 | 2417,563,NA 12 | 291,NA,2128 13 | 291,NA,2180 14 | 286,596,NA 15 | 314,1168,NA 16 | 286,596,NA 17 | 2261,1050,NA 18 | 295,87,NA 19 | 294,1324,NA 20 | 10,NA,1138 21 | 2261,1050,NA 22 | 286,596,NA 23 | 284,1533,NA 24 | 285,1530,NA 25 | 3507,879,NA 26 | 100,1142,NA 27 | 3817,1142,NA 28 | 59,NA,85 29 | 61,NA,370 30 | 2350,878,NA 31 | 274,1531,NA 32 | 277,1428,NA 33 | 277,NA,2109 34 | 255,2018,NA 35 | 307,1161,NA 36 | 2393,1400,NA 37 | 274,1531,NA 38 | 2250,2008,NA 39 | 3902,1138,NA 40 | 3902,1138,NA 41 | 13973,NA,830 42 | 2043,588,NA 43 | 2271,NA,3218 44 | 3218,NA,3218 45 | 2042,19,NA 46 | 63,2614,NA 47 | 3903,1224,NA 48 | 2083,3123,NA 49 | 2114,NA,3072 50 | 3606,NA,3072 51 | 3810,NA,2897 52 | 3799,NA,2757 53 | 3785,NA,3363 54 | 3681,NA,2714 55 | 3516,NA,3364 56 | 3876,NA,2715 57 | 3871,NA,3439 58 | 3871,NA,3218 59 | 319,2568,NA 60 | 2206,2532,NA 61 | -------------------------------------------------------------------------------- /GROA-ForC_integration/GROA-ForC mapping/GROA-ForC variable mapping.csv: -------------------------------------------------------------------------------- 1 | GROA order,GROA table,GROA field,GROA Description,-,ForC order,ForC table,ForC Column,ForC field,ForC Description,ForC Storage.Type,ForC Variable.Codes,ForC Units,-,Value to assign - value entered,Value to assign - missing values,manual.review.needed,Clarifications needed,notes,action needed,For_modificaition needed, 2 | ,,,,-,1,MEASUREMENTS,1 / A,measurement.ID,Unique identifier for each record in the measurements table.,numeric (integer),-,-,-,(counting up from latest record),,,,,code,, 3 | 8,MEASUREMENTS,sites.sitename,,-,2,MEASUREMENTS,2 / B,sites.sitename,"Unique site identifier name for the site at which the measurement was made. Links to SITES, PLOTS and HISTORY tables. ",character (string),-,-,-,-,-,-,-,-,-,-,- 4 | 9,MEASUREMENTS,refor.type,"reforestation type or reference condition: SNR = Spontaneous natural regeneration, ANR = assisted natural regeneration, ITP = initial tree planting, DP = diverse species plantation, MP = monoculture plantation, TMC = intensive tree monocrop, MS = multistrata, TI = tree intercropping, SP = silvopastoral systems, TR = transitional, C = cropland (reference), PA = pasture (reference), OG = old growth (intact forest reference)",-,3,MEASUREMENTS,3 / C,plot.name,Unique plot identifier name for the plot in which the measurement was made. Links to HISTORY and PLOTS table.,character (string),-,-,-,"SNR = regrowth stand regenerating via spontaneous natural regeneration, ANR =regrowth stand regenerating via assisted natural regeneration, ITP = regrowth stand regenerating via initial tree planting, DP = diverse species plantation, MP = monoculture plantation, TMC = intensive tree monocrop, MS = multistrata stand, TI = stand with tree intercropping, SP = silvopastoral system, TR = transitional ecosystem, C = cropland, PA = pasture, OG = intact/ old growth stand. ",,,,,code,, 5 | 13,MEASUREMENTS,stand.age,age of forest stand: C & PA = 0; OG = 999; otherwise as given in paper,-,4,MEASUREMENTS,4 / D,stand.age,"Age of stand at time of measurement as reported in the original publication or calculated based on the date of initiation of forest regrowth. When the publication reports a range of ages, the mean is recorded. For stands that were reported as primary/old-growth/mature/ intact stands, the stand.age is recorded as ""999"". WARNING: The ""999"" designation may include some older secondary stands that were designated ""mature"" or some partially disturbed primary stands (e.g., partially logged).",numeric (double),see description,years,-,value,,-,-,-,-,-, 6 | 9,MEASUREMENTS,refor.type,"reforestation type or reference condition: SNR = Spontaneous natural regeneration, ANR = assisted natural regeneration, ITP = initial tree planting, DP = diverse species plantation, MP = monoculture plantation, TMC = intensive tree monocrop, MS = multistrata, TI = tree intercropping, SP = silvopastoral systems, TR = transitional, C = cropland (reference), PA = pasture (reference), OG = old growth (intact forest reference)",-,5,MEASUREMENTS,5 / E,dominant.life.form,"Dominant life form at time of measurement, with categories including ""woody"" (trees, seedlings, or shrubs), ""grass"", and ""woody+grass"" (i.e., savanna). ",character (string),see description,-,-,"if refor.type= anytihng but C or PA, ""woody"". If refor.type=PA, ""2GW'. If refor.type=C, ""NAC""",,,,,code,, 7 | ,,,,-,6,MEASUREMENTS,6 / F,dominant.veg,"Code used to identify plant functional type of dominant vegetation at time of measurement. For trees, groupings are based on leaf type (broadleaf /needleleaf/ mixed) and phenology (deciduous/ evergreen/ mixed), and dominance is defined based on an 80% threshold (if given). If vegetation is a mix of trees and other vegetation, codes refer to the functional type of trees. For vegetation with no significant tree species component, groupings are by life form, if any. ",character (string),Given in PFT table,-,-,NAC,,,,"a lot of this could be derived from GROA species/ ForC veg.notes, perhaps with automated code (by searching for keywords)",code?,, 8 | -,-,-,,-,7,MEASUREMENTS,7 / G,scientific.name,"Genus and species for single dominant species at time of measurement, if applicable.",character (string),-,-,-,-,-,-,-,-,-,-,- 9 | 10,MEASUREMENTS,Species,name of dominant species,-,8,MEASUREMENTS,8 / H,veg.notes,"Notes on the vegetation at time of measurement (e.g., forest type/ list of dominant species). For single species, field gives species name acronym, as listed in the USDA Plants Checklist (http://plants.usda.gov/dl_all.html). ",character (string),-,-,-,value,"""NA""",-,,"put in notes, as opposed to scientific.name because ForC only lists species for monodominant stands. (1) these are all naturally regeneratingsub(tropical) secondary forests, so monodominance is not realistic,and (2) while most records are single scientific names, some are other descriptions or multiple species",-,-,- 10 | 17,MEASUREMENTS,variables.name,stock name,-,9,MEASUREMENTS,9 / I,variable.name,Code name for variable sampled. ,character (string),Given in VARIABLES table,-,-,(see variable_name_conversion.csv),-,-,-,-,-,, 11 | 21,MEASUREMENTS,density,number of individual trees per hectare,-,9,MEASUREMENTS,9 / I,variable.name,Code name for variable sampled. ,character (string),Given in VARIABLES table,n ha-1,-,stand.density,[none],-,-,"when there is a value, create a record (row) in measurements. Otehrwise, disregard",-,-, 12 | 14,MEASUREMENTS,date,collection date for data,-,10,MEASUREMENTS,10 / J,date,"Date on which measurement was made. Usually found as the year of measurement in the methods section, or, when unavailable, approximated as the year before publication. ",numeric (double),-,decimal years,-,value,"""NI"" ",-,-,-,-,-, 13 | -,-,-,-,-,11,MEASUREMENTS,11 / K,date.loc,Level of confidence in date. ,numeric (double),Given in dateLOC table,-,-,8,9,-,-,-,-,, 14 | -,-,-,-,-,12,MEASUREMENTS,12 / L,start.date,Date on which measurements were started.,numeric (double),,decimal years,-,NA,-,-,-,-,code,, 15 | -,-,-,-,-,13,MEASUREMENTS,13 / M,start.date.loc,Level of confidence in date. ,numeric (double),Given in dateLOC table,-,-,9,-,-,-,-,code,, 16 | -,-,-,-,-,14,MEASUREMENTS,14 / N,end.date,Date on which measurements ended.,numeric (double),,decimal years,-,NA,-,-,-,-,code,, 17 | -,-,-,-,-,15,MEASUREMENTS,15 / O,end.date.loc,Level of confidence in date. ,numeric (double),Given in dateLOC table,-,-,9,-,-,-,-,code,, 18 | 18,MEASUREMENTS,mean_ha,value of biomass or carbon estimate,-,16,MEASUREMENTS,16 / P,mean,Mean value of measurement recorded. Units depend on the variable and can be found in the VARIABLES table. ,numeric (double) ,-,Given in VARIABLES table,-,value,[none],-,-,-,-,, 19 | 21,MEASUREMENTS,density,number of individual trees per hectare,-,16,MEASUREMENTS,16 / P,mean,Mean value of measurement recorded. Units depend on the variable and can be found in the VARIABLES table. ,numeric (double) ,,n ha-1,-,value,[none],-,-,"when there is a value, create a record (row) in measurements. Otehrwise, disregard",-,-,- 20 | 15,MEASUREMENTS,n,number of plots per site and stand age,-,17,MEASUREMENTS,17 / Q,n,Number of experimental replicates used to estimate mean and statistical summary.,numeric (integer) ,-,-,-,value,"""NI"" ",-,-,-,-,-,- 21 | -,-,-,-,-,18,MEASUREMENTS,18 / R,stat.name,Name of reported statistic (SE- standard error; SD- standard deviation; 95%CI- 95% confidence interval). ,character (string),see description,-,-,-,-,-,-,-,-,-,- 22 | -,-,-,-,-,19,MEASUREMENTS,19 / S,stat,Value of reported statistic.,numeric (double),-,VARIABLES table,-,-,-,-,-,-,-,-,- 23 | 16,MEASUREMENTS,plot.size,hectares,-,20,MEASUREMENTS,20 / T,area.sampled,"Area sampled for measurement of the particular variable. If the measurement includes multiple components with different sampling area (e.g., large trees sampled in the entire plot, small trees sampled in subplots), the largest area is reported. This may be less than plot.area (PLOTS table). As this field was added after most of the data had been entered, it is coded as ""NAC"" for most records.",numeric (double),-,ha,-,[GROA n] x [GROA plot.size],NI,-,-,-,code,-,- 24 | 15.5,MEASUREMENTS,sub.n,"number of subplots, e.g., soil samples that are pooled",-,21,MEASUREMENTS,21 / U,notes,"Additional information about the record, including notes on methodology and notes on any known anomalies. Potentially problematic values have notes prefaced with asterisks. ",character (string),-,-,-,"""[value] samples per plot""",-,-,-,-,-,-,- 25 | 24,MEASUREMENTS,allometry,direct harvest = when all biomass is harvested; site-specific harvest = based on trees harvested at the site; species-specific; forest-type-specific; biome-specifi,-,21,MEASUREMENTS,21 / U,notes,"Additional information about the record, including notes on methodology and notes on any known anomalies. Potentially problematic values have notes prefaced with asterisks. ",character (string),-,-,-,"""Biomass allometries: [value]""",,,,"allometries are classified as to specificity, does not record original source",code,, 26 | -,-,-,-,-,23,MEASUREMENTS,23 / W,allometry_1,Code number for allometry (when it is a required covariate).,numeric (integer),Given in ALLOMETRY table,-,-,"""NAC""",-,-,-,-,code,-,- 27 | -,-,-,-,-,24,MEASUREMENTS,24 / X,allometry_2,Code number for allometry (when it is a required covariate).,numeric (integer),Given in ALLOMETRY table,-,-,"""NAC""",-,-,-,-,-,-,- 28 | 20,MEASUREMENTS,coV1_value,value of covariate 1,-,25,MEASUREMENTS,25 / Y,min.dbh,"Minimum diameter (typically DBH, diameter at breast height) of tree stems included in the measurement. ""0"" indicates that all stems were included.",numeric (integer),,cm,-,see https://github.com/forc-db/GROA/issues/8,NAC,-,-,-,-,-, 29 | -,-,-,,-,26,MEASUREMENTS,26 / Z,depth,Depth of measurement if belowground or including belowground components,numeric (integer),-,cm,-,see https://github.com/forc-db/GROA/issues/8,NAC,,,"for soil variables, GROA has lots of soil profiles. We will transform all into cumulative values by max depth (as opposed to reporting for the soil layer)",,, 30 | 19,MEASUREMENTS,covar_1 ,"type of covariate: max_depth; max_height; min_height; min_depth; root_diameter_max; root_diameter_min; soil_type; other min_dbh; min_diameter; min_height; min_length ",-,27,MEASUREMENTS,27 / AA,covariate_1,Code name for covariate associated with the variable being measured. Codes defined in VARIABLES table.,character (string),-,-,-,see https://github.com/forc-db/GROA/issues/8,NA,-,-,-,-,-, 31 | 20,MEASUREMENTS,coV1_value,value of covariate 1,-,28,MEASUREMENTS,28 / AB,coV_1.value,Value of reported covariate.,character (string),-,VARIABLES table,-,see https://github.com/forc-db/GROA/issues/8,NA,-,-,-,-,-, 32 | -,-,-,-,-,29,MEASUREMENTS,29 / AC,covariate_2,Code name for covariate associated with the variable being measured. Codes defined in VARIABLES table.,character (string),-,-,-,see https://github.com/forc-db/GROA/issues/8,NA,-,-,-,-,-, 33 | -,-,-,-,-,30,MEASUREMENTS,30 / AD,coV_2.value,Value of reported covariate.,numeric (double) ,-,VARIABLES table,-,see https://github.com/forc-db/GROA/issues/8,NA,-,-,-,-,-, 34 | -,-,-,-,-,31,MEASUREMENTS,31 / AE,conflicts,"Indicates whether the record is independent or whether there is some sort of conflict/overlap with any other record. There may be more than one. Records are classified as subsuming others when their measurement period includes that of another record or when measurement dates are unknown, indicating a potential conflict. Duplicates are measurements of the same variable (C or OM) in the same plot (or overlapping plot) at the same time (or overlapping time).",character (string) ,I- idependent; R- replicate; S/s- Subsumes (S)/ is subsumed by (s) another record; D- Duplicates another record.,-,-,NA,NA,-,-,-,-,-, 35 | -,-,-,-,-,32,MEASUREMENTS,32 / AF,R.group,Number idenifying a group of replicates.,numeric (double) ,-,-,-,NA,NA,-,-,-,-,-, 36 | -,-,-,-,-,33,MEASUREMENTS,33 / AG,S.group,"Number identifying a group of non-independent records where one or more record subsumes another / others (e.g., one measurement period includes another).",numeric (double) ,-,-,-,NA,NA,-,-,-,-,-, 37 | -,-,-,-,-,34,MEASUREMENTS,34 / AH,D.group,Number identifying a group of non-independent records that duplicate or overlap one another as defined in D.type field.,numeric (double) ,-,-,-,NA,NA,-,-,-,-,-, 38 | -,-,-,-,-,35,MEASUREMENTS,35 / AI,D.precedence,"Indicates whether or not the duplicate record is assigned default precedence. Precendence is assigned as follows: For duplicates that differ in methodology (M), plot (P), or have overlapping time periods (T), higher priority is assigned to the more comprehensive measurement (e.g., including trees + understory as opposed to just trees, sampling roots to greater depth, larger plot, longer time period) or that which is generally considered to be methodologically more rigorous. When priority was not clear based on the information in the database at the time that ranks were assigned (March 2018), precendence is given to the more recent study. If two sources were published in the same year, the primary source (as opposed to a synthesis) comes first. ",numeric (double) ,0- no precedence; 1- precedence,-,-,NA,NA,-,-,-,-,-, 39 | -,-,-,-,-,36,MEASUREMENTS,36 / AJ,conflict.type,Code(s) indicating conflict type for S and D groups. There may be more than one.,character (string),T- overlapping time period; P- overlapping or nested plots; M- methods differ; C- records differ in units (C / OM),-,-,NA,NA,-,-,-,-,-, 40 | -,-,-,-,-,37,MEASUREMENTS,37 / AK,conflicts.notes,Notes clarifying relationships among conflicted recrods.,character (string),-,-,-,NA,NA,-,-,-,-,-, 41 | -,-,-,-,-,38,MEASUREMENTS,38 / AL,citation.ID,Citation ID for publication from which measurements were obtained. Citation.ID is in the form [last name of first author]_[year]_[first letter of first four words of title] and links to citation.ID in the citations table.,character (string) ,-,-,-,citation.ID (see description under ForC Citations table),,-,-,-,-,-, 42 | -,-,-,-,-,39,MEASUREMENTS,39 / AM,loaded.from,"Citation ID(s) for data compilations from which data and reference to primary source were obtained, if applicable. Citation.ID is in the form [last name of first author]_[year]_[first letter of first four words of title] and links to citation.ID in the citations table.",character (string) ,-,-,-,"[Cook-Patton database citation, in ForC format]",,-,-,-,code,-, 43 | 3,MEASUREMENTS,measurement.id,unique identifier per measurement,-,40,MEASUREMENTS,40 / AN,source.notes,Notes on data source. Source notes were originally entered in notes column; some source notes may remain there.,character (string) ,-,-,-,GROA measurement.ID # [value],,-,-,-,code,-, 44 | -,-,-,-,-,41,MEASUREMENTS,41 / AO,measurement.ID.v1,"Original measurement.ID, where numbers <3568 correspond to records released in the first published version of the database (Anderson-Teixeira et al., 2016). Other numbers correspond to records in a previous master version of the database (2ForC_data_measurements.xlsx; archived in ForC_private). ",numeric (integer),-,-,-,"""NA""",,-,-,-,code,, 45 | -,-,-,-,-,43,MEASUREMENTS,43 / AQ,loaded.by,Name of individual who created the record,character (string) ,-,-,-,"""R script by [NAME]""",,-,-,-,,, 46 | -,-,-,-,-,44,MEASUREMENTS,44 / AR,checked.ori.pub,"Indicates whether we have confirmation that the measurement value (mean) has been checked against the source listed in citation.ID (as opposed to the loaded.from source). This field likely contains a lot of false negatives, as it wasn't added until February 2018.",numeric (integer),1-true; 0- false,-,-,"""1"" for all studies, except ""0"" for Guo and Krankina",,-,-,-,-,-, 47 | -,-,-,-,-,45,MEASUREMENTS,45 / AS,ForC.investigator,"Name, institution, and email address of the corresponding author for the database record. This is the individual who should be contacted with correspondence regarding that record (e.g., questions, corrections, requests for collaboration). ",character (string) ,-,-,-,Dr. Susan Cook-Patton,,-,-,-,-,-, 48 | ,,,,-,46,MEASUREMENTS,46 / AT,flag.suspicious,Field indicating suspicious measurement values that should not be used in analysis until confirmed. Reason for supicion described in notes field. ,numeric (integer),1-true; 0- false,-,-,0,,-,-,-,-,-, 49 | ,,,,-,47,SITES,1 / A,site.ID,Unique numerical identifier for each record in the SITES table.,numeric (integer),-,-,-,(counting up from latest record),,,,,code,, 50 | 29,SITES,site.sitename,,-,48,SITES,2 / B,sites.sitename,"Site identifier, sufficient to uniquely identify the site within the paper. Links to MEASUREMENTS, PLOTS, and HISTORY tables.",character (string),-,-,-,value,,-,-,-,code,-, 51 | ,,,,-,49,SITES,3 / C,city,"Nearest city, when identified in original publication.",character (string),-,-,-,"""NAC""",NAC,,,,code,, 52 | 30,SITES,site.state,"sub-national jurisdiction such as state, province etc.",-,50,SITES,4 / D,state,State / province/ region,character (string),-,-,-,value,NAC,-,-,-,code,-, 53 | 31,SITES,site.country,country name,-,51,SITES,5 / E,country,Country,character (string),-,-,-,value,NAC,-,-,-,code,-, 54 | 32,SITES,lat_dec,latitude,-,52,SITES,6 / F,lat,"Latitude, where negative values indicate S hemisphere",numeric (double),-,decimal degrees,-,value,NAC,-,-,-,code,-, 55 | 33,SITES,long_dec,longitude,-,53,SITES,7 / G,lon,"Longitude, where negative values indicate W hemisphere",numeric (double),-,decimal degrees,-,value,NAC,-,-,-,code,-, 56 | 35,SITES,elevation,height above sea level,-,54,SITES,8 / H,masl,"Elevation in meters above sea level. When a range is given, midpoint is reported.",numeric (double),-,m ,-,value,NAC,-,-,-,code,-, 57 | ,,,,-,55,SITES,9 / I,geography.notes,"Notes pertaining to site name, location, or topography",character (string),-,-,-,NA,NA,,,,code,, 58 | 36,SITES,AMT,annual mean precipitation,-,56,SITES,10 / J,mat,Mean annual temperature ,numeric (double),-,C,-,value,NAC,-,-,-,code,-, 59 | -,-,-,-,-,57,SITES,11 / K,min.temp,Mean temperature of the coldest month ,numeric (double),-,C,-,NAC,NAC,,,,code,, 60 | -,-,-,-,-,58,SITES,12 / L,max.temp,Mean temperature of the warmest month,numeric (double),-,C,-,NAC,NAC,,,,code,, 61 | 37,SITES,AMP,annual mean temperature,-,59,SITES,13 / M,map,Mean annual precipitation ,numeric (double),-,mm,-,value,NAC,-,-,-,code,-, 62 | -,-,-,-,-,60,SITES,14 / N,climate.notes,Climate details not included above,character (string),-,-,-,NA,NA,,,,code,, 63 | ,,,,-,61,SITES,15 / O,soil.texture,"Soil texture, based on % sand-silt-clay. When original publication reports % sand-silt-clay, classification follows USDA soil classification. ",character (string),-,-,-,"when GROA value is textural description (e.g., clay), use that",NAC,,,,code,, 64 | 22,MEASUREMENTS,sand.silt.clay,"soil texture: %:%:% or description (e.g., clay, sandy clay, sandy clay loam, loamy sand, silty clay, silt loam)",-,62,SITES,16 / P,sand,,,,,-,"when GROA value is [V1:V2:V3], V1. If there are multiple values for the site, average them.",-,-,-,Would typically be the same through time for a plot (although there is one study where this was remeasured at the site level). Can differ between plots at a single site.,code,-,- 65 | 22,MEASUREMENTS,sand.silt.clay,"soil texture: %:%:% or description (e.g., clay, sandy clay, sandy clay loam, loamy sand, silty clay, silt loam)",-,63,SITES,17 / Q,silt,,,,,,"when GROA value is [V1:V2:V3], V2. If there are multiple values for the site, average them.",-,-,-,Would typically be the same through time for a plot (although there is one study where this was remeasured at the site level). Can differ between plots at a single site.,code,-,- 66 | 22,MEASUREMENTS,sand.silt.clay,"soil texture: %:%:% or description (e.g., clay, sandy clay, sandy clay loam, loamy sand, silty clay, silt loam)",-,64,SITES,18 / R,clay,,,,,,"when GROA value is [V1:V2:V3], V3. If there are multiple values for the site, average them.",-,-,-,Would typically be the same through time for a plot (although there is one study where this was remeasured at the site level). Can differ between plots at a single site.,code,-,- 67 | 38,SITES,soil.classification,,-,65,SITES,19 / S,soil.classification,Soil classification (USDA soil taxonomy or FAO soil classification),character (string),-,-,-,value,NAC,-,-,-,code,-, 68 | ,,,,-,66,SITES,20 / T,soil.notes,Soil details not included above,character (string),-,-,-,NA,NA,,,,code,, 69 | ,,,,-,67,SITES,21 / U,hydrology.notes,"Notes on sites hydrology (e.g., terra firma, seasonally flooded) ",character (string),-,-,-,NA,NA,,,,code,, 70 | ,,,,-,68,SITES,22 / V,site.notes,Site details not included above,character (string),-,-,-,NA,NA,,,,code,, 71 | ,,,,-,69,SITES,23 / W,geographic.area,"Groups geographically proximate sites, where proximity was defined using a hierarchical cluster analysis on the distance matrix of the sites and a cutoff of 25km (R script available in the Github scripts folder).",numeric (integer) ,-,-,-,(to be entered later by script),,,,,code,, 72 | -,-,-,-,-,70,SITES,24 / X,biogeog,"Biogeographical region, extracted from map of (Olson et al. 2001)",character (string),-,-,-,(to be entered later from external database),,,,,code,, 73 | -,-,-,-,-,71,SITES,25 / Y,Koeppen,"Koppen-Geiger classification, extracted from the ESRI Koppen-Geiger map (http://www.arcgis.com/home/item.html?id=7a53584fa55643df969f93cec83788e1).",character (string),Given in Table 1 of Peel et al. (2007),-,-,(to be entered later from external database),,,,,code,, 74 | -,-,-,-,-,72,SITES,26 / Z,FAO.ecozone,"FAO global ecological zones classification, extracted from FAO's GeoNetwork (http://www.fao.org:80/geonetwork).",character (string),-,-,-,(to be entered later from external database),,,,,code,, 75 | -,-,-,-,-,73,SITES,27 / AA,site.ID.v1,"Original site.ID, where numbers <=503 correspond to records released in the first published version of the database (Anderson-Teixeira et al., 2016)",numeric (integer),-,-,-,NA,,-,-,-,code,-, 76 | -,-,-,-,-,74,SITES,28 / AB,tropical.extratropical,Indicates whether data is from tropical or extratropical regions.,character (string),"tropical, extratropical",-,-,"|lat| >=23.5--> ""tropical"", else ""extratropical""",,-,-,-,code,-, 77 | ,,,,-,75,SITES,29 / AC,site.ref,"Citation ID(s) of reference from which site data were obtained. ""NA"" indicates that all site data were obtained from references associated with measurement data. Citation.ID is in the form [last name of first author]_[year]_[first letter of first four words of title] and links to citation.ID in the citations table.",character (string),-,-,-,NA,,,,,code,, 78 | 5,MEASUREMENTS,site.id,"unique identifier for each site, defined as a unique geolocation. This site.id differs from ForC site.id in that ForC will assign different site.IDs to the same geolocation if edaphic /biophysical condidtions differ.",-,76,SITES,30 / AD,ref.notes,"Notes on references for site data, including citations of publications not included in the ForC references library.",character (string),-,-,-,"""GROA site.ID = [value]""",,,,,code,, 79 | ,,,,-,77,SITES,31 / AE,lacks.info.from.ori.pub,Indicates studies that were flagged because they lack information obtained directly from the original study. A missing value code ('NA') does not necessarily guarantee that information was obtained from an original publication. ,numeric (integer),1- lacks info from original pub,-,-,0,,,,,code,, 80 | ,,,,-,78,SITES,32 / AF,loaded.from,"Citation ID(s) of data compilations from which data were obtained, if applicable. Citation.ID is in the form [last name of first author]_[year]_[first letter of first four words of title] and links to citation.ID in the citations table.",character (string),-,-,-,"[Cook-Patton database citation, in ForC format]",,,,,code,, 81 | ,,,,,79,SITES,33 / AG,loaded.by,Name of individual who created the record,character (string),-,-,-,"""R script by [NAME]""",,,,,code,, 82 | ,,,,-,80,HISTORY,1 / A,history.ID,Unique numerical identifier for each record in the history table. ,numeric (decimal),-,-,-,(counting up from latest record),-,,,,-,, 83 | ,,,,-,81,HISTORY,2 / B,sites.sitename,"Unique site identifier, sufficient to identify the site within the original publication. Links to SITES, PLOTS and MEASUREMENTS tables.",character (string),-,-,-,(see MEASUREMENTS),-,,,,-,, 84 | ,,,,-,82,HISTORY,3 / C,plot.name,"Unique plot name, sufficient to identify the plot within the original publication.",character (string),-,-,-,(see MEASUREMENTS),-,,,,-,, 85 | ,,,,-,83,HISTORY,4 / D,plot.area,Area of plot or combined area of replicate plots.,numeric (double),-,ha,-,(same as recorded in MEASUREMENTS if variable is / includes biomass. Not for soils.),NAC,,,,-,, 86 | ,,,,-,84,HISTORY,5 / E,event.sequence,"Order of event within the sequence of existing records. This allows determination of event order when dates are missing or events have the same date. NOTE: This field was created after original data entry based on order entered and notes, not in consultation with original publications. ",numeric (integer),-,-,-,see separate instructions document,,,,,create instructions,, 87 | ,,,,-,85,HISTORY,6 / F,date,Date of plot history event.,character (string),-,decimal years,-,see separate instructions document,,,,,create instructions,, 88 | ,,,,-,86,HISTORY,7 / G,date.loc,Level of confidence in date.,numeric (double),Given in dateLOC table,-,-,see separate instructions document,,,,,create instructions,, 89 | ,,,,-,87,HISTORY,8 / H,hist.cat,Plot history event categories.,"string (mixed upper and lower case letters, numbers, and special characters)",Given in HISTTYPE metadata table,-,-,see separate instructions document,,,,,create instructions,, 90 | ,,,,-,88,HISTORY,9 / I,hist.type,Plot history event types. ,"string (mixed upper and lower case letters, numbers, and special characters)",Given in HISTTYPE metadata table,-,-,see separate instructions document,,,,,create instructions,, 91 | ,,,,-,89,HISTORY,10 / J,est.regrowth.assumed.same.year,"Indicates whether it is assumed that establishment of the oldest trees and regrowth (e.g., initiation of post-disturbance cohort, planting) occurred in the same year. These may differ if there was a lag in tree establishment following a severe/stand clearing disturbance or if some trees survived the most recent severe/stand clearing disturbance. ",numeric (integer),0- false; 1- true,-,-,see separate instructions document,,,,,create instructions,, 92 | ,,,,-,90,HISTORY,11 / K,level,"Intensity/frequency/amount applied of history event type, if available.",character (string),-,-,-,see separate instructions document,,,,,create instructions,, 93 | ,,,,-,91,HISTORY,12 / L,units,Level units.,character (string),-,-,-,see separate instructions document,,,,,create instructions,, 94 | ,,,,-,92,HISTORY,13 / M,percent.mortality,Percent tree mortality resulting from disturbance. 100% mortality is assumed for slash-and-burn and cultivation.,numeric (double),"""<100%"" - non- stand clearing disturbance (% mortality unkonwn/ unspecified); ""<<100%"" - very minor disturbance",-,-,see separate instructions document,,,,,create instructions,, 95 | ,,,,-,93,HISTORY,14 / N,hist.notes,History event details not included above.,character (string),-,-,-,see separate instructions document,,,,,create instructions,, 96 | ,,,,-,94,HISTORY,15 / N,plothistory.ID.v1,"Original plothistory.ID, where numbers <=2441 correspond to records released in the first published version of the database (Anderson-Teixeira et al., 2015)",numeric (integer),-,-,-,NA,NA,-,-,-,-,-,- 97 | ,,,,-,97,METHODOLOGY,1 / A,method.ID,Code name for methodology. Used in MEASUREMENTS table. ,numeric (double) ,-,-,-,(no new methodology records scripted),,,,,-,, 98 | ,,,,-,98,METHODOLOGY,2 / B,method.citation,Citation ID for publication describing the allometries. ID is in the form [last name of first author]_[year]_[first letter of first four words of title] and links to the citations table. References to non-publications are not coded,character (string) ,-,-,-,(no new methodology records scripted),,,,,-,, 99 | ,,,,-,99,METHODOLOGY,3 / C,variable.name,"The type of variable for which the methodology is described. May not exactly correspond to variable.name in VARIABLES table, as similar variables may be grouped together.",character (string) ,-,-,-,(no new methodology records scripted),,,,,-,, 100 | ,,,,-,100,METHODOLOGY,4 / D,method.notes,Description of the methodology used.,character (string) ,-,-,-,(no new methodology records scripted),,,,,-,, 101 | ,,,,-,101,METHODOLOGY,4 / D,method.notes,Description of the methodology used.,character (string) ,-,-,-,(no new methodology records scripted),,,,,-,, 102 | -,-,-,-,-,102,CITATIONS,1 / A,citation.ID,"Citation ID in the form [last name of first author]_[year]_[first letter of first four words of title, when applicable]. ",character (string),-,-,-,"create citation ID in the form [last name of first author]_[publication year]_[first letter of first four words of title, when applicable, counting hyphenated words as single words]. ",,-,-,-,-,-,- 103 | -,-,-,-,-,103,CITATIONS,2 / B,citation.doi,Citation DOI,character (string),-,-,-,"""NAC""",,-,-,-,-,-,- 104 | 41,LITERATURE,citations.author,last name of first author,-,104,CITATIONS,3 / C,citation.author,Last name of first author of citation,character (string),-,-,-,value,,-,-,-,-,-,- 105 | 42,LITERATURE,citations.year,year of publication,-,105,CITATIONS,4 / D,citation.year,Year of publication,numeric (double),-,-,-,value,,-,-,-,-,-,- 106 | 7,MEASUREMENTS,citations.title,full title from publication,-,106,CITATIONS,5 / E,citation.title,Title of publication.,character (string),-,-,-,value,,-,-,-,-,-,- 107 | 44,LITERATURE,citations.title,full title from publication,-,106,CITATIONS,5 / E,citation.title,Title of publication.,character (string),-,-,-,value,,-,-,-,-,-,- 108 | 1,MEASUREMENTS,IPCC,?,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,- 109 | 2,MEASUREMENTS,country,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,- 110 | 4,MEASUREMENTS,plot.id,unique identifier per plot,-,-,-,-,-,-,-,-,-,-,-,-,-,-,not the same as ForC,-,, 111 | 6,MEASUREMENTS,study.id,unique identifier per publication,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,- 112 | 23,MEASUREMENTS,pH,,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,- 113 | 25,MEASUREMENTS,measurements.notes,"any ambiguities, assumptions, or judgement calls",-,-,-,-,-,-,-,-,-,-,-,-,will need manual review to place in appropriate fields,-,-,-,-,- 114 | 26,SITES,study.id,unique identifier per publication,-,-,-,-,-,-,-,-,-,-,,,,-,not the same as ForC,-,, 115 | 27,SITES,site.id,"unique identifier for each site, defined as a unique geolocation",-,-,-,-,-,-,-,-,-,-,,,,-,not the same as ForC,-,, 116 | 39,SITES,site.notes,"any sources of ambiguity, judgement calls etc.",-,-,-,-,-,-,-,-,-,-,-,-,will need manual review to place in appropriate fields,-,-,-,-,- 117 | 40,LITERATURE,study.id,unique identifier per publication,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,- 118 | 43,LITERATURE,citations.journal,citation information,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,- 119 | 45,LITERATURE,citations.notes,"any relevant details here such as ambiguities, key assumptions, or judgement calls",-,-,-,-,-,-,-,-,-,-,-,-,will need manual review to place in appropriate fields,-,-,-,-,- 120 | 9,MEASUREMENTS,refor.type,"reforestation type or reference condition: SNR = Spontaneous natural regeneration, ANR = assisted natural regeneration, ITP = initial tree planting, DP = diverse species plantation, MP = monoculture plantation, TMC = intensive tree monocrop, MS = multistrata, TI = tree intercropping, SP = silvopastoral systems, TR = transitional, C = cropland (reference), PA = pasture (reference), OG = old growth (intact forest reference)",-,,(HISTORY),,,,,,,-,,,,,,create instructions,, 121 | 11,MEASUREMENTS,prior,prior land use: C = crop; SC = shifting cultivation/fallow agriculture/slash and burn agriculture; H = clearcut harvest; F= fire; D = non-fire disturbance such as landslide or hurricane; PA = pasture; OG = old growth (only relevant for intact stand which have no prior condition),-,,(HISTORY),,,,,,,-,,,,,,create instructions,, 122 | 12,MEASUREMENTS,prior.duration,,-,,(HISTORY),,,,,,,-,,,,,put in notes. Will require manual review to fill in other History fields.,create instructions,, 123 | 20.1,MEASUREMENTS,covar_2,,-,,,,,,,,,,see https://github.com/forc-db/GROA/issues/8,NA,-,-,-,-,-, 124 | 20.2,MEASUREMENTS,coV2_value,,-,,,,,,,,,,see https://github.com/forc-db/GROA/issues/8,NA,-,-,-,-,-, 125 | 20.3,MEASUREMENTS,covar_3,,-,,,,,,,,,,see https://github.com/forc-db/GROA/issues/8,NA,-,-,-,-,-, 126 | 20.4,MEASUREMENTS,coV3_value,,-,,,,,,,,,,see https://github.com/forc-db/GROA/issues/8,NA,-,-,-,-,-, 127 | ,,,,-,,,,,,,,,,,,,,,,, -------------------------------------------------------------------------------- /GROA-ForC_integration/GROA-ForC mapping/GROA-ForC_sites_mapping.csv: -------------------------------------------------------------------------------- 1 | "ForC.site.ID","GROA.site.ID" 2 | 1,13943 3 | 19,2042 4 | 50,13948 5 | 87,295 6 | 100,310 7 | 160,13902 8 | 186,345 9 | 272,269 10 | 286,13910 11 | 288,13914 12 | 291,13944 13 | 295,13952 14 | 311,13927 15 | 324,13932 16 | 396,3575 17 | 399,13921 18 | 402,13923 19 | 413,13929 20 | 419,13949 21 | 431,13937 22 | 486,13906 23 | 511,13915 24 | 528,13939 25 | 533,13951 26 | 534,13912 27 | 535,13918 28 | 559,363 29 | 562,13911 30 | 563,293 31 | 565,13919 32 | 588,2043 33 | 596,286 34 | 597,2021 35 | 602,13907 36 | 746,13953 37 | 749,13925 38 | 774,13916 39 | 800,273 40 | 862,2039 41 | 870,2236 42 | 878,2350 43 | 879,3507 44 | 947,2040 45 | 949,13955 46 | 957,13938 47 | 974,6901 48 | 988,13924 49 | 1010,309 50 | 1050,2261 51 | 1063,13926 52 | 1142,100 53 | 1159,13904 54 | 1161,307 55 | 1168,314 56 | 1224,3903 57 | 1258,13950 58 | 1268,19 59 | 1310,13909 60 | 1322,303 61 | 1324,294 62 | 1337,3716 63 | 1400,2393 64 | 1420,13945 65 | 1426,13931 66 | 1428,277 67 | 1438,304 68 | 1447,290 69 | 1450,13941 70 | 1452,13901 71 | 1453,13903 72 | 1464,283 73 | 1478,13908 74 | 1481,13942 75 | 1507,13917 76 | 1530,285 77 | 1531,274 78 | 1533,284 79 | 1549,3528 80 | 1557,344 81 | 1558,13933 82 | 1606,13920 83 | 1641,13930 84 | 1642,13928 85 | 1673,13934 86 | 1683,3623 87 | 1740,3650 88 | 1747,54 89 | 1792,13935 90 | 1826,342 91 | 1829,13940 92 | 1863,13936 93 | 1868,2396 94 | 1871,3625 95 | 1879,13913 96 | 1886,13954 97 | 1895,13947 98 | 1897,13946 99 | 1912,3793 100 | 1928,3641 101 | 1952,3604 102 | 1953,3591 103 | 1954,3733 104 | 1955,3815 105 | 1956,3624 106 | 1957,3825 107 | 1958,3743 108 | 1959,3518 109 | 1960,3543 110 | 1961,3772 111 | 1962,3704 112 | 1978,3535 113 | 2008,2250 114 | 2009,346 115 | 2018,255 116 | 2044,2025 117 | 2049,13922 118 | 2532,2206 119 | 2568,319 120 | 2614,63 121 | 3123,2083 122 | 3423,3582 123 | 3424,13956 124 | 3425,13982 125 | 3426,3884 126 | 3427,3885 127 | 3428,2257 128 | 3429,13976 129 | 3430,3907 130 | 3431,2112 131 | 3432,444 132 | 3433,2145 133 | 3434,2354 134 | 3435,289 135 | 3436,3871 136 | 3437,3897 137 | 3438,3140 138 | 3439,14102 139 | 3440,14104 140 | 3441,14105 141 | 3442,14106 142 | 3443,14107 143 | 3444,14108 144 | 3445,14110 145 | 3446,14111 146 | 3447,14112 147 | 3448,14113 148 | 3449,14114 149 | 3450,14115 150 | 3451,14116 151 | 3452,14117 152 | 3453,14118 153 | 3454,14120 154 | 3455,14121 155 | 3456,14122 156 | 3457,14123 157 | 3458,14125 158 | 3459,14126 159 | 3460,14127 160 | 3461,14128 161 | 3462,14132 162 | 3463,14133 163 | 3464,14134 164 | 3465,14135 165 | 3466,14136 166 | 3467,14137 167 | 3468,14138 168 | 3469,14139 169 | 3470,14140 170 | 3471,14141 171 | 3472,14142 172 | 3473,14144 173 | 3474,14146 174 | 3475,14147 175 | 3476,14148 176 | 3477,14149 177 | 3478,14151 178 | 3479,14154 179 | 3480,14155 180 | 3481,14156 181 | 3482,14158 182 | 3483,14159 183 | 3484,14160 184 | 3485,14161 185 | 3486,14162 186 | 3487,14163 187 | 3488,14169 188 | 3489,14170 189 | 3490,14172 190 | 3491,14173 191 | 3492,14174 192 | 3493,14177 193 | 3494,14178 194 | 3495,14184 195 | 3496,14186 196 | 3497,14187 197 | 3498,14189 198 | 3499,14190 199 | 3500,14192 200 | 3501,14194 201 | 3502,14195 202 | 3503,14196 203 | 3504,14197 204 | 3505,14204 205 | 3506,14205 206 | 3507,14206 207 | 3508,14207 208 | 3509,14208 209 | 3510,14209 210 | 3511,14218 211 | 3512,14219 212 | 3513,14221 213 | 3514,14222 214 | 3515,14223 215 | 3516,14224 216 | 3517,14225 217 | 3518,14226 218 | 3519,14227 219 | 3520,14228 220 | 3521,14229 221 | 3522,14230 222 | 3523,14231 223 | 3524,14232 224 | 3525,14233 225 | 3526,14234 226 | 3527,14235 227 | 3528,14237 228 | 3529,14238 229 | 3530,14240 230 | 3531,14241 231 | 3532,14242 232 | 3533,14244 233 | 3534,14245 234 | 3535,14246 235 | 3536,14247 236 | 3537,14248 237 | 3538,14250 238 | 3539,14251 239 | 3540,14254 240 | 3541,14255 241 | 3542,14258 242 | 3543,14259 243 | 3544,14260 244 | 3545,14261 245 | 3546,14262 246 | 3547,14263 247 | 3548,14264 248 | 3549,14265 249 | 3550,3508 250 | 3551,3898 251 | 3552,3566 252 | 3553,3683 253 | 3554,3686 254 | 3555,3784 255 | 3556,3695 256 | 3557,3570 257 | 3558,3723 258 | 3559,13972 259 | 3560,3662 260 | 3561,3703 261 | 3562,3826 262 | 3563,13977 263 | 3564,2217 264 | 3565,2218 265 | 3566,2219 266 | 3567,2220 267 | 3568,2221 268 | 3569,2222 269 | 3570,2223 270 | 3571,2224 271 | 3572,2225 272 | 3573,2226 273 | 3574,2227 274 | 3575,2391 275 | 3576,2413 276 | 3577,2092 277 | 3578,297 278 | 3579,3006 279 | 3580,56 280 | 3581,3899 281 | 3582,3900 282 | 3583,343 283 | 3584,2504 284 | 3585,2241 285 | 3586,2242 286 | 3587,2243 287 | 3588,14131 288 | 3589,14150 289 | 3590,14152 290 | 3591,14153 291 | 3592,14167 292 | 3593,14168 293 | 3594,14175 294 | 3595,14179 295 | 3596,14180 296 | 3597,14181 297 | 3598,14182 298 | 3599,14183 299 | 3600,14185 300 | 3601,14188 301 | 3602,14193 302 | 3603,14198 303 | 3604,14199 304 | 3605,14200 305 | 3606,14201 306 | 3607,14202 307 | 3608,14203 308 | 3609,14210 309 | 3610,14211 310 | 3611,14212 311 | 3612,14213 312 | 3613,14214 313 | 3614,14215 314 | 3615,14216 315 | 3616,14217 316 | 3617,14220 317 | 3618,14236 318 | 3619,14239 319 | 3620,14243 320 | 3621,14249 321 | 3622,14252 322 | 3623,14253 323 | 3624,14256 324 | 3625,14257 325 | 3626,425 326 | 3627,3572 327 | 3628,49 328 | 3629,13973 329 | 3630,398 330 | 3631,2048 331 | 3632,2049 332 | 3633,2050 333 | 3634,2051 334 | 3635,2052 335 | 3636,2053 336 | 3637,2054 337 | 3638,2055 338 | 3639,2056 339 | 3640,2057 340 | 3641,2058 341 | 3642,2059 342 | 3643,2060 343 | 3644,2061 344 | 3645,2062 345 | 3646,2063 346 | 3647,2064 347 | 3648,2065 348 | 3649,2066 349 | 3650,2067 350 | 3651,2068 351 | 3652,2069 352 | 3653,2070 353 | 3654,2071 354 | 3655,13971 355 | 3656,2332 356 | 3657,2444 357 | 3658,22 358 | 3659,426 359 | 3660,40 360 | 3661,64 361 | 3662,2116 362 | 3663,3767 363 | 3664,6902 364 | 3665,3529 365 | 3666,13957 366 | 3667,2305 367 | 3668,2174 368 | 3669,2090 369 | 3670,2096 370 | 3671,2098 371 | 3672,2100 372 | 3673,3759 373 | 3674,13964 374 | 3675,13967 375 | 3676,2357 376 | 3677,278 377 | 3678,39 378 | 3679,41 379 | 3680,140 380 | 3681,243 381 | 3682,291 382 | 3683,2259 383 | 3684,2377 384 | 3685,3705 385 | 3686,55 386 | 3687,60 387 | 3688,2379 388 | 3689,2114 389 | 3690,3710 390 | 3691,2150 391 | 3692,3606 392 | 3693,399 393 | 3694,3877 394 | 3695,3878 395 | 3696,14006 396 | 3697,2094 397 | 3698,298 398 | 3699,412 399 | 3700,417 400 | 3701,419 401 | 3702,420 402 | 3703,421 403 | 3704,423 404 | 3705,424 405 | 3706,435 406 | 3707,2175 407 | 3708,3789 408 | 3709,10 409 | 3710,59 410 | 3711,67 411 | 3712,2137 412 | 3713,2304 413 | 3714,3774 414 | 3715,238 415 | 3716,2003 416 | 3717,2010 417 | 3718,2151 418 | 3719,2152 419 | 3720,14005 420 | 3721,2110 421 | 3722,105 422 | 3723,2037 423 | 3724,2289 424 | 3725,2291 425 | 3726,2292 426 | 3727,13983 427 | 3728,13984 428 | 3729,13985 429 | 3730,36 430 | 3731,37 431 | 3733,175 432 | 3734,386 433 | 3735,14103 434 | 3736,14109 435 | 3737,14119 436 | 3738,14124 437 | 3739,14129 438 | 3740,14130 439 | 3741,14143 440 | 3742,14145 441 | 3743,14157 442 | 3744,14164 443 | 3745,14165 444 | 3746,14166 445 | 3747,14171 446 | 3748,14176 447 | 3749,14191 448 | 3750,7 449 | 3751,8 450 | 3752,9 451 | 3753,11 452 | 3754,14 453 | 3755,15 454 | 3756,16 455 | 3757,18 456 | 3758,42 457 | 3759,43 458 | 3760,44 459 | 3761,46 460 | 3762,47 461 | 3763,48 462 | 3764,51 463 | 3765,58 464 | 3766,61 465 | 3767,66 466 | 3768,68 467 | 3769,209 468 | 3770,210 469 | 3771,211 470 | 3772,212 471 | 3773,226 472 | 3774,227 473 | 3775,229 474 | 3776,388 475 | 3777,434 476 | 3778,441 477 | 3779,442 478 | 3780,2015 479 | 3781,2016 480 | 3782,2028 481 | 3783,2029 482 | 3784,2030 483 | 3785,2031 484 | 3786,2032 485 | 3787,2046 486 | 3788,2073 487 | 3790,2121 488 | 3791,2122 489 | 3792,2123 490 | 3793,2124 491 | 3794,2125 492 | 3795,2126 493 | 3796,2127 494 | 3797,2128 495 | 3798,2129 496 | 3799,2130 497 | 3800,2156 498 | 3801,2158 499 | 3802,2164 500 | 3803,2165 501 | 3804,2179 502 | 3805,2180 503 | 3806,2229 504 | 3807,2283 505 | 3808,2286 506 | 3809,2287 507 | 3810,2362 508 | 3811,2382 509 | 3812,2383 510 | 3813,2384 511 | 3814,2385 512 | 3815,2398 513 | 3816,2401 514 | 3817,2403 515 | 3818,2405 516 | 3819,2505 517 | 3820,2506 518 | 3821,2509 519 | 3822,3509 520 | 3823,3538 521 | 3824,3628 522 | 3825,3649 523 | 3826,3661 524 | 3827,3699 525 | 3828,3765 526 | 3829,3781 527 | 3830,3800 528 | 3831,3816 529 | 3832,3863 530 | 3833,3886 531 | 3834,3887 532 | 3835,3888 533 | 3836,3889 534 | 3837,3890 535 | 3838,3891 536 | 3839,3893 537 | 3840,3894 538 | 3841,3895 539 | 3842,3896 540 | 3843,3901 541 | 3844,3956 542 | 3845,3957 543 | 3846,3958 544 | 3847,3959 545 | 3848,3960 546 | 3849,3961 547 | 3850,3962 548 | 3851,3963 549 | 3852,3964 550 | 3853,3965 551 | 3854,3966 552 | 3855,3967 553 | 3856,3968 554 | 3857,3969 555 | 3858,3970 556 | 3859,3971 557 | 3860,3972 558 | 3861,3973 559 | 3862,3974 560 | 3863,3975 561 | 3864,3976 562 | 3865,3977 563 | 3866,3978 564 | 3867,3979 565 | 3868,3980 566 | 3869,3981 567 | 3870,3982 568 | 3871,3983 569 | 3872,3984 570 | 3873,3985 571 | 3874,3986 572 | 3875,3987 573 | 3876,3988 574 | 3877,3989 575 | 3878,3990 576 | 3879,3991 577 | 3880,3992 578 | 3881,3993 579 | 3882,3994 580 | 3883,3995 581 | 3884,3996 582 | 3885,3997 583 | 3886,3998 584 | 3887,3999 585 | 3888,4000 586 | 3889,4001 587 | 3890,4002 588 | 3891,4003 589 | 3892,4004 590 | 3893,4005 591 | 3894,4006 592 | 3895,4007 593 | 3896,4008 594 | 3897,4009 595 | 3898,4010 596 | 3899,4011 597 | 3900,4012 598 | 3901,4013 599 | 3902,4014 600 | 3903,4015 601 | 3904,4016 602 | 3905,4017 603 | 3906,4018 604 | 3907,4019 605 | 3908,4020 606 | 3909,4021 607 | 3910,4022 608 | 3911,4023 609 | 3912,4024 610 | 3913,4025 611 | 3914,4026 612 | 3915,4027 613 | 3916,4028 614 | 3917,4029 615 | 3918,4030 616 | 3919,4031 617 | 3920,4032 618 | 3921,4033 619 | 3922,4034 620 | 3923,4035 621 | 3924,4036 622 | 3925,4037 623 | 3926,4038 624 | 3927,4039 625 | 3928,4040 626 | 3929,4041 627 | 3930,4042 628 | 3931,4043 629 | 3932,4044 630 | 3933,4045 631 | 3934,4046 632 | 3935,4047 633 | 3936,4048 634 | 3937,4049 635 | 3938,4050 636 | 3939,4051 637 | 3940,4052 638 | 3941,4053 639 | 3942,4054 640 | 3943,4055 641 | 3944,4056 642 | 3945,4057 643 | 3946,4058 644 | 3947,4059 645 | 3948,4060 646 | 3949,4061 647 | 3950,4062 648 | 3951,4063 649 | 3952,4064 650 | 3953,4065 651 | 3954,4066 652 | 3955,4067 653 | 3956,4068 654 | 3957,4069 655 | 3958,4070 656 | 3959,4071 657 | 3960,4072 658 | 3961,4074 659 | 3962,4075 660 | 3963,4076 661 | 3964,4077 662 | 3965,4078 663 | 3966,4079 664 | 3967,4080 665 | 3968,4081 666 | 3969,4082 667 | 3970,4083 668 | 3971,4084 669 | 3972,4085 670 | 3973,4086 671 | 3974,4087 672 | 3975,4088 673 | 3976,4089 674 | 3977,4090 675 | 3978,4091 676 | 3979,4092 677 | 3980,4093 678 | 3981,4095 679 | 3982,4096 680 | 3983,4097 681 | 3984,4098 682 | 3985,4099 683 | 3986,4100 684 | 3987,4101 685 | 3988,4102 686 | 3989,4103 687 | 3990,4104 688 | 3991,4105 689 | 3992,4106 690 | 3993,4107 691 | 3994,4108 692 | 3995,4109 693 | 3996,4110 694 | 3997,4111 695 | 3998,4112 696 | 3999,4113 697 | 4000,4114 698 | 4001,4115 699 | 4002,4116 700 | 4003,4117 701 | 4004,4118 702 | 4005,4119 703 | 4006,4120 704 | 4007,4121 705 | 4008,4122 706 | 4009,4123 707 | 4010,4124 708 | 4011,4125 709 | 4012,4126 710 | 4013,4127 711 | 4014,4128 712 | 4015,4129 713 | 4016,4130 714 | 4017,4131 715 | 4018,4132 716 | 4019,4133 717 | 4020,4134 718 | 4021,4135 719 | 4022,4136 720 | 4023,4137 721 | 4024,4138 722 | 4025,4139 723 | 4026,4140 724 | 4027,4141 725 | 4028,4142 726 | 4029,4143 727 | 4030,4144 728 | 4031,4145 729 | 4032,4146 730 | 4033,4147 731 | 4034,4148 732 | 4035,4149 733 | 4036,4150 734 | 4037,4151 735 | 4038,4152 736 | 4039,4153 737 | 4040,4154 738 | 4041,4155 739 | 4042,4156 740 | 4043,4157 741 | 4044,4158 742 | 4045,4159 743 | 4046,4160 744 | 4047,4161 745 | 4048,4162 746 | 4049,4163 747 | 4050,4164 748 | 4051,4165 749 | 4052,4166 750 | 4053,4167 751 | 4054,4168 752 | 4055,4169 753 | 4056,4170 754 | 4057,4171 755 | 4058,4172 756 | 4059,4173 757 | 4060,4174 758 | 4061,4175 759 | 4062,4176 760 | 4063,4177 761 | 4064,4178 762 | 4065,4179 763 | 4066,4180 764 | 4067,4181 765 | 4068,4182 766 | 4069,4183 767 | 4070,4184 768 | 4071,4185 769 | 4072,4186 770 | 4073,4187 771 | 4074,4188 772 | 4075,4189 773 | 4076,4190 774 | 4077,4191 775 | 4078,4192 776 | 4079,4193 777 | 4080,4194 778 | 4081,4195 779 | 4082,4196 780 | 4083,4197 781 | 4084,4198 782 | 4085,4199 783 | 4086,4200 784 | 4087,4201 785 | 4088,4202 786 | 4089,4203 787 | 4090,4204 788 | 4091,4205 789 | 4092,4206 790 | 4093,4207 791 | 4094,4208 792 | 4095,4209 793 | 4096,4210 794 | 4097,4211 795 | 4098,4212 796 | 4099,4213 797 | 4100,4214 798 | 4101,4215 799 | 4102,4216 800 | 4103,4217 801 | 4104,4218 802 | 4105,4219 803 | 4106,4220 804 | 4107,4221 805 | 4108,4222 806 | 4109,4223 807 | 4110,4224 808 | 4111,4225 809 | 4112,4226 810 | 4113,4227 811 | 4114,4228 812 | 4115,4229 813 | 4116,4230 814 | 4117,4231 815 | 4118,4232 816 | 4119,4233 817 | 4120,4234 818 | 4121,4235 819 | 4122,4236 820 | 4123,4238 821 | 4124,4239 822 | 4125,4240 823 | 4126,4241 824 | 4127,4242 825 | 4128,4243 826 | 4129,4244 827 | 4130,4245 828 | 4131,4246 829 | 4132,4247 830 | 4133,4248 831 | 4134,4249 832 | 4135,4250 833 | 4136,4251 834 | 4137,4252 835 | 4138,4253 836 | 4139,4254 837 | 4140,4255 838 | 4141,4256 839 | 4142,4257 840 | 4143,4258 841 | 4144,4259 842 | 4145,4260 843 | 4146,4261 844 | 4147,4262 845 | 4148,4263 846 | 4149,4264 847 | 4150,4265 848 | 4151,4266 849 | 4152,4267 850 | 4153,4268 851 | 4154,4269 852 | 4155,4270 853 | 4156,4271 854 | 4157,4272 855 | 4158,4273 856 | 4159,4274 857 | 4160,4275 858 | 4161,4276 859 | 4162,4277 860 | 4163,4278 861 | 4164,4279 862 | 4165,4280 863 | 4166,4281 864 | 4167,4282 865 | 4168,4283 866 | 4169,4284 867 | 4170,4285 868 | 4171,4286 869 | 4172,4287 870 | 4173,4288 871 | 4174,4289 872 | 4175,4290 873 | 4176,4291 874 | 4177,4292 875 | 4178,4293 876 | 4179,4294 877 | 4180,4295 878 | 4181,4296 879 | 4182,4297 880 | 4183,4298 881 | 4184,4299 882 | 4185,4300 883 | 4186,4301 884 | 4187,4302 885 | 4188,4303 886 | 4189,4304 887 | 4190,4305 888 | 4191,4306 889 | 4192,4307 890 | 4193,4308 891 | 4194,4309 892 | 4195,4310 893 | 4196,4311 894 | 4197,4312 895 | 4198,4313 896 | 4199,4314 897 | 4200,4315 898 | 4201,4316 899 | 4202,4317 900 | 4203,4318 901 | 4204,4319 902 | 4205,4320 903 | 4206,4321 904 | 4207,4322 905 | 4208,4323 906 | 4209,4324 907 | 4210,4325 908 | 4211,4326 909 | 4212,4327 910 | 4213,4328 911 | 4214,4329 912 | 4215,4330 913 | 4216,4331 914 | 4217,4332 915 | 4218,4333 916 | 4219,4334 917 | 4220,4335 918 | 4221,4336 919 | 4222,4337 920 | 4223,4338 921 | 4224,4339 922 | 4225,4340 923 | 4226,4341 924 | 4227,4342 925 | 4228,4343 926 | 4229,4344 927 | 4230,4345 928 | 4231,4346 929 | 4232,4347 930 | 4233,4348 931 | 4234,4349 932 | 4235,4350 933 | 4236,4351 934 | 4237,4352 935 | 4238,4353 936 | 4239,4354 937 | 4240,4355 938 | 4241,4356 939 | 4242,4357 940 | 4243,4358 941 | 4244,4359 942 | 4245,4360 943 | 4246,4361 944 | 4247,4362 945 | 4248,4363 946 | 4249,4364 947 | 4250,4365 948 | 4251,4366 949 | 4252,4367 950 | 4253,4368 951 | 4254,4369 952 | 4255,4370 953 | 4256,4371 954 | 4257,4372 955 | 4258,4373 956 | 4259,4374 957 | 4260,4375 958 | 4261,4376 959 | 4262,4377 960 | 4263,4378 961 | 4264,4379 962 | 4265,4380 963 | 4266,4381 964 | 4267,4382 965 | 4268,4383 966 | 4269,4384 967 | 4270,4385 968 | 4271,4386 969 | 4272,4387 970 | 4273,4388 971 | 4274,4389 972 | 4275,4390 973 | 4276,4391 974 | 4277,4392 975 | 4278,4393 976 | 4279,4394 977 | 4280,4395 978 | 4281,4396 979 | 4282,4397 980 | 4283,4398 981 | 4284,4399 982 | 4285,4400 983 | 4286,4401 984 | 4287,4402 985 | 4288,4403 986 | 4289,4404 987 | 4290,4405 988 | 4291,4406 989 | 4292,4407 990 | 4293,4409 991 | 4294,4410 992 | 4295,4411 993 | 4296,4412 994 | 4297,4413 995 | 4298,4414 996 | 4299,4415 997 | 4300,4416 998 | 4301,4418 999 | 4302,4419 1000 | 4303,4420 1001 | 4304,4421 1002 | 4305,4422 1003 | 4306,4423 1004 | 4307,4424 1005 | 4308,4425 1006 | 4309,4426 1007 | 4310,4427 1008 | 4311,4428 1009 | 4312,4429 1010 | 4313,4430 1011 | 4314,4431 1012 | 4315,4432 1013 | 4316,4433 1014 | 4317,4434 1015 | 4318,4436 1016 | 4319,4437 1017 | 4320,4438 1018 | 4321,4439 1019 | 4322,4440 1020 | 4323,4441 1021 | 4324,4442 1022 | 4325,4443 1023 | 4326,4444 1024 | 4327,4445 1025 | 4328,4448 1026 | 4329,4449 1027 | 4330,4450 1028 | 4331,4451 1029 | 4332,4452 1030 | 4333,4453 1031 | 4334,4454 1032 | 4335,4455 1033 | 4336,4456 1034 | 4337,4457 1035 | 4338,4458 1036 | 4339,4459 1037 | 4340,4460 1038 | 4341,4461 1039 | 4342,4462 1040 | 4343,4463 1041 | 4344,4464 1042 | 4345,4465 1043 | 4346,4466 1044 | 4347,4467 1045 | 4348,4468 1046 | 4349,4469 1047 | 4350,4470 1048 | 4351,4472 1049 | 4352,4473 1050 | 4353,4474 1051 | 4354,4475 1052 | 4355,4476 1053 | 4356,4477 1054 | 4357,4478 1055 | 4358,4479 1056 | 4359,4480 1057 | 4360,4481 1058 | 4361,4482 1059 | 4362,4483 1060 | 4363,4484 1061 | 4364,4485 1062 | 4365,4486 1063 | 4366,4487 1064 | 4367,4491 1065 | 4368,4492 1066 | 4369,4499 1067 | 4370,4500 1068 | 4371,4501 1069 | 4372,4504 1070 | 4373,4505 1071 | 4374,4506 1072 | 4375,4508 1073 | 4376,4564 1074 | 4377,4565 1075 | 4378,4566 1076 | 4379,4567 1077 | 4380,4568 1078 | 4381,4569 1079 | 4382,4570 1080 | 4383,4571 1081 | 4384,4572 1082 | 4385,4573 1083 | 4386,4574 1084 | 4387,4575 1085 | 4388,4576 1086 | 4389,4577 1087 | 4390,4578 1088 | 4391,4579 1089 | 4392,4580 1090 | 4393,4581 1091 | 4394,4582 1092 | 4395,4583 1093 | 4396,4584 1094 | 4397,4585 1095 | 4398,4586 1096 | 4399,4587 1097 | 4400,4588 1098 | 4401,4589 1099 | 4402,4590 1100 | 4403,4591 1101 | 4404,4592 1102 | 4405,4593 1103 | 4406,4594 1104 | 4407,4595 1105 | 4408,4596 1106 | 4409,4597 1107 | 4410,4598 1108 | 4411,4599 1109 | 4412,4600 1110 | 4413,4601 1111 | 4414,4602 1112 | 4415,4603 1113 | 4416,4604 1114 | 4417,4605 1115 | 4418,4606 1116 | 4419,4607 1117 | 4420,4608 1118 | 4421,4609 1119 | 4422,4610 1120 | 4423,4611 1121 | 4424,4612 1122 | 4425,4613 1123 | 4426,4614 1124 | 4427,4615 1125 | 4428,4616 1126 | 4429,4617 1127 | 4430,4618 1128 | 4431,4621 1129 | 4432,4622 1130 | 4433,4623 1131 | 4434,4624 1132 | 4435,4690 1133 | 4436,4691 1134 | 4437,4692 1135 | 4438,4693 1136 | 4439,4694 1137 | 4440,4695 1138 | 4441,4696 1139 | 4442,4697 1140 | 4443,4698 1141 | 4444,4699 1142 | 4445,4700 1143 | 4446,4701 1144 | 4447,4702 1145 | 4448,4703 1146 | 4449,4704 1147 | 4450,4705 1148 | 4451,4706 1149 | 4452,4707 1150 | 4453,4708 1151 | 4454,4709 1152 | 4455,4710 1153 | 4456,4711 1154 | 4457,4712 1155 | 4458,4713 1156 | 4459,4714 1157 | 4460,4715 1158 | 4461,4716 1159 | 4462,4717 1160 | 4463,4718 1161 | 4464,4719 1162 | 4465,4720 1163 | 4466,4721 1164 | 4467,4722 1165 | 4468,4723 1166 | 4469,4724 1167 | 4470,4725 1168 | 4471,4726 1169 | 4472,4727 1170 | 4473,4728 1171 | 4474,4729 1172 | 4475,4730 1173 | 4476,4731 1174 | 4477,4732 1175 | 4478,4733 1176 | 4479,4734 1177 | 4480,4735 1178 | 4481,4736 1179 | 4482,4737 1180 | 4483,4738 1181 | 4484,4739 1182 | 4485,4740 1183 | 4486,4741 1184 | 4487,4742 1185 | 4488,4743 1186 | 4489,4744 1187 | 4490,4745 1188 | 4491,4746 1189 | 4492,4747 1190 | 4493,4748 1191 | 4494,4749 1192 | 4495,4750 1193 | 4496,4751 1194 | 4497,4752 1195 | 4498,4753 1196 | 4499,4754 1197 | 4500,4755 1198 | 4501,4756 1199 | 4502,4757 1200 | 4503,4758 1201 | 4504,4759 1202 | 4505,4760 1203 | 4506,4761 1204 | 4507,4762 1205 | 4508,4763 1206 | 4509,4764 1207 | 4510,4765 1208 | 4511,4766 1209 | 4512,4767 1210 | 4513,4768 1211 | 4514,4769 1212 | 4515,4770 1213 | 4516,4771 1214 | 4517,4772 1215 | 4518,4773 1216 | 4519,4774 1217 | 4520,4775 1218 | 4521,4776 1219 | 4522,4777 1220 | 4523,4778 1221 | 4524,4779 1222 | 4525,4780 1223 | 4526,4781 1224 | 4527,4782 1225 | 4528,4783 1226 | 4529,4784 1227 | 4530,4785 1228 | 4531,4786 1229 | 4532,4787 1230 | 4533,4789 1231 | 4534,4790 1232 | 4535,4791 1233 | 4536,4792 1234 | 4537,4793 1235 | 4538,4794 1236 | 4539,4796 1237 | 4540,4797 1238 | 4541,4798 1239 | 4542,4799 1240 | 4543,4800 1241 | 4544,4801 1242 | 4545,4802 1243 | 4546,4803 1244 | 4547,4804 1245 | 4548,4805 1246 | 4549,4806 1247 | 4550,4807 1248 | 4551,4808 1249 | 4552,4809 1250 | 4553,4810 1251 | 4554,4811 1252 | 4555,4812 1253 | 4556,4813 1254 | 4557,4814 1255 | 4558,4815 1256 | 4559,4816 1257 | 4560,4817 1258 | 4561,4818 1259 | 4562,4819 1260 | 4563,4820 1261 | 4564,4821 1262 | 4565,4822 1263 | 4566,4823 1264 | 4567,4824 1265 | 4568,4825 1266 | 4569,4826 1267 | 4570,4827 1268 | 4571,4828 1269 | 4572,4829 1270 | 4573,4830 1271 | 4574,4831 1272 | 4575,4832 1273 | 4576,4833 1274 | 4577,4834 1275 | 4578,4835 1276 | 4579,4836 1277 | 4580,4837 1278 | 4581,4838 1279 | 4582,4839 1280 | 4583,4840 1281 | 4584,4841 1282 | 4585,4843 1283 | 4586,4844 1284 | 4587,4845 1285 | 4588,4846 1286 | 4589,4847 1287 | 4590,4848 1288 | 4591,4849 1289 | 4592,4850 1290 | 4593,4851 1291 | 4594,4852 1292 | 4595,4853 1293 | 4596,4854 1294 | 4597,4860 1295 | 4598,4863 1296 | 4599,4864 1297 | 4600,4865 1298 | 4601,4866 1299 | 4602,4869 1300 | 4603,4874 1301 | 4604,4875 1302 | 4605,4876 1303 | 4606,4877 1304 | 4607,4878 1305 | 4608,4879 1306 | 4609,4880 1307 | 4610,4883 1308 | 4611,4885 1309 | 4612,4886 1310 | 4613,4887 1311 | 4614,4888 1312 | 4615,4892 1313 | 4616,4893 1314 | 4617,4894 1315 | 4618,4895 1316 | 4619,4896 1317 | 4620,4897 1318 | 4621,4898 1319 | 4622,4899 1320 | 4623,4901 1321 | 4624,4902 1322 | 4625,4903 1323 | 4626,4904 1324 | 4627,4905 1325 | 4628,4906 1326 | 4629,4907 1327 | 4630,4908 1328 | 4631,4909 1329 | 4632,4910 1330 | 4633,4911 1331 | 4634,4912 1332 | 4635,4913 1333 | 4636,4914 1334 | 4637,4915 1335 | 4638,4916 1336 | 4639,4917 1337 | 4640,4918 1338 | 4641,4919 1339 | 4642,4920 1340 | 4643,4921 1341 | 4644,4922 1342 | 4645,4923 1343 | 4646,4924 1344 | 4647,4925 1345 | 4648,4926 1346 | 4649,4927 1347 | 4650,4928 1348 | 4651,4929 1349 | 4652,4930 1350 | 4653,4931 1351 | 4654,4932 1352 | 4655,4933 1353 | 4656,4934 1354 | 4657,4935 1355 | 4658,4936 1356 | 4659,4937 1357 | 4660,4939 1358 | 4661,4940 1359 | 4662,4941 1360 | 4663,4942 1361 | 4664,4943 1362 | 4665,4944 1363 | 4666,4945 1364 | 4667,4946 1365 | 4668,4947 1366 | 4669,4948 1367 | 4670,4949 1368 | 4671,4950 1369 | 4672,4951 1370 | 4673,4952 1371 | 4674,4953 1372 | 4675,4954 1373 | 4676,4955 1374 | 4677,4956 1375 | 4678,4957 1376 | 4679,4958 1377 | 4680,4959 1378 | 4681,4960 1379 | 4682,4961 1380 | 4683,4962 1381 | 4684,4963 1382 | 4685,4964 1383 | 4686,4965 1384 | 4687,4966 1385 | 4688,4967 1386 | 4689,4969 1387 | 4690,4970 1388 | 4691,4971 1389 | 4692,4972 1390 | 4693,4973 1391 | 4694,4974 1392 | 4695,4975 1393 | 4696,4977 1394 | 4697,4978 1395 | 4698,4979 1396 | 4699,4980 1397 | 4700,4981 1398 | 4701,4982 1399 | 4702,4983 1400 | 4703,4984 1401 | 4704,4985 1402 | 4705,4986 1403 | 4706,4987 1404 | 4707,4988 1405 | 4708,4989 1406 | 4709,4990 1407 | 4710,4991 1408 | 4711,4992 1409 | 4712,4993 1410 | 4713,4994 1411 | 4714,4995 1412 | 4715,4996 1413 | 4716,4997 1414 | 4717,4998 1415 | 4718,4999 1416 | 4719,5000 1417 | 4720,5001 1418 | 4721,5002 1419 | 4722,5003 1420 | 4723,5004 1421 | 4724,5005 1422 | 4725,5006 1423 | 4726,5007 1424 | 4727,5008 1425 | 4728,5009 1426 | 4729,5010 1427 | 4730,5011 1428 | 4731,5012 1429 | 4732,5013 1430 | 4733,5014 1431 | 4734,5015 1432 | 4735,5016 1433 | 4736,5017 1434 | 4737,5018 1435 | 4738,5019 1436 | 4739,5020 1437 | 4740,5021 1438 | 4741,5022 1439 | 4742,5023 1440 | 4743,5024 1441 | 4744,5025 1442 | 4745,5026 1443 | 4746,5027 1444 | 4747,5028 1445 | 4748,5029 1446 | 4749,5030 1447 | 4750,5031 1448 | 4751,5032 1449 | 4752,5033 1450 | 4753,5034 1451 | 4754,5035 1452 | 4755,5036 1453 | 4756,5037 1454 | 4757,5038 1455 | 4758,5039 1456 | 4759,5040 1457 | 4760,5041 1458 | 4761,5042 1459 | 4762,5043 1460 | 4763,5044 1461 | 4764,5045 1462 | 4765,5046 1463 | 4766,5047 1464 | 4767,5048 1465 | 4768,5049 1466 | 4769,5050 1467 | 4770,5051 1468 | 4771,5052 1469 | 4772,5053 1470 | 4773,5054 1471 | 4774,5055 1472 | 4775,5056 1473 | 4776,5057 1474 | 4777,5058 1475 | 4778,5059 1476 | 4779,5060 1477 | 4780,5061 1478 | 4781,5062 1479 | 4782,5063 1480 | 4783,5064 1481 | 4784,5065 1482 | 4785,5066 1483 | 4786,5067 1484 | 4787,5068 1485 | 4788,5069 1486 | 4789,5070 1487 | 4790,5071 1488 | 4791,5072 1489 | 4792,5073 1490 | 4793,5074 1491 | 4794,5075 1492 | 4795,5076 1493 | 4796,5077 1494 | 4797,5078 1495 | 4798,5079 1496 | 4799,5080 1497 | 4800,5081 1498 | 4801,5082 1499 | 4802,5083 1500 | 4803,5084 1501 | 4804,5085 1502 | 4805,5086 1503 | 4806,5087 1504 | 4807,5088 1505 | 4808,5089 1506 | 4809,5090 1507 | 4810,5091 1508 | 4811,5092 1509 | 4812,5093 1510 | 4813,5094 1511 | 4814,5095 1512 | 4815,5096 1513 | 4816,5097 1514 | 4817,5098 1515 | 4818,5099 1516 | 4819,5100 1517 | 4820,5101 1518 | 4821,5102 1519 | 4822,5103 1520 | 4823,5104 1521 | 4824,5105 1522 | 4825,5106 1523 | 4826,5107 1524 | 4827,5108 1525 | 4828,5109 1526 | 4829,5110 1527 | 4830,5111 1528 | 4831,5112 1529 | 4832,5113 1530 | 4833,5114 1531 | 4834,5115 1532 | 4835,5116 1533 | 4836,5117 1534 | 4837,5118 1535 | 4838,5119 1536 | 4839,5120 1537 | 4840,5121 1538 | 4841,5122 1539 | 4842,5123 1540 | 4843,5124 1541 | 4844,5125 1542 | 4845,5126 1543 | 4846,5127 1544 | 4847,5128 1545 | 4848,5129 1546 | 4849,5130 1547 | 4850,5131 1548 | 4851,5132 1549 | 4852,5133 1550 | 4853,5134 1551 | 4854,5135 1552 | 4855,5136 1553 | 4856,5137 1554 | 4857,5138 1555 | 4858,5139 1556 | 4859,5140 1557 | 4860,5141 1558 | 4861,5142 1559 | 4862,5143 1560 | 4863,5144 1561 | 4864,5145 1562 | 4865,5146 1563 | 4866,5147 1564 | 4867,5148 1565 | 4868,5149 1566 | 4869,5150 1567 | 4870,5151 1568 | 4871,5152 1569 | 4872,5153 1570 | 4873,5154 1571 | 4874,5155 1572 | 4875,5156 1573 | 4876,5157 1574 | 4877,5158 1575 | 4878,5159 1576 | 4879,5160 1577 | 4880,5161 1578 | 4881,5162 1579 | 4882,5163 1580 | 4883,5164 1581 | 4884,5165 1582 | 4885,5166 1583 | 4886,5167 1584 | 4887,5168 1585 | 4888,5169 1586 | 4889,5170 1587 | 4890,5171 1588 | 4891,5172 1589 | 4892,5173 1590 | 4893,5174 1591 | 4894,5175 1592 | 4895,5176 1593 | 4896,5177 1594 | 4897,5178 1595 | 4898,5179 1596 | 4899,5180 1597 | 4900,5181 1598 | 4901,5182 1599 | 4902,5183 1600 | 4903,5184 1601 | 4904,5185 1602 | 4905,5186 1603 | 4906,5187 1604 | 4907,5188 1605 | 4908,5189 1606 | 4909,5190 1607 | 4910,5191 1608 | 4911,5192 1609 | 4912,5193 1610 | 4913,5194 1611 | 4914,5195 1612 | 4915,5196 1613 | 4916,5197 1614 | 4917,5198 1615 | 4918,5199 1616 | 4919,5200 1617 | 4920,5201 1618 | 4921,5202 1619 | 4922,5203 1620 | 4923,5204 1621 | 4924,5205 1622 | 4925,5206 1623 | 4926,5207 1624 | 4927,5208 1625 | 4928,5209 1626 | 4929,5210 1627 | 4930,5211 1628 | 4931,5212 1629 | 4932,5213 1630 | 4933,5214 1631 | 4934,5215 1632 | 4935,5216 1633 | 4936,5217 1634 | 4937,5218 1635 | 4938,5219 1636 | 4939,5220 1637 | 4940,5221 1638 | 4941,5222 1639 | 4942,5223 1640 | 4943,5224 1641 | 4944,5225 1642 | 4945,5226 1643 | 4946,5227 1644 | 4947,5228 1645 | 4948,5229 1646 | 4949,5230 1647 | 4950,5231 1648 | 4951,5232 1649 | 4952,5233 1650 | 4953,5234 1651 | 4954,5235 1652 | 4955,5236 1653 | 4956,5237 1654 | 4957,5238 1655 | 4958,5239 1656 | 4959,5240 1657 | 4960,5241 1658 | 4961,5242 1659 | 4962,5244 1660 | 4963,5245 1661 | 4964,5246 1662 | 4965,5247 1663 | 4966,5248 1664 | 4967,5249 1665 | 4968,5250 1666 | 4969,5251 1667 | 4970,5252 1668 | 4971,5253 1669 | 4972,5254 1670 | 4973,5255 1671 | 4974,5256 1672 | 4975,5257 1673 | 4976,5258 1674 | 4977,5259 1675 | 4978,5260 1676 | 4979,5261 1677 | 4980,5262 1678 | 4981,5263 1679 | 4982,5264 1680 | 4983,5265 1681 | 4984,5266 1682 | 4985,5267 1683 | 4986,5268 1684 | 4987,5269 1685 | 4988,5270 1686 | 4989,5271 1687 | 4990,5272 1688 | 4991,5273 1689 | 4992,5274 1690 | 4993,5275 1691 | 4994,5276 1692 | 4995,5277 1693 | 4996,5278 1694 | 4997,5280 1695 | 4998,5281 1696 | 4999,5282 1697 | 5000,5283 1698 | 5001,5284 1699 | 5002,5285 1700 | 5003,5286 1701 | 5004,5287 1702 | 5005,5288 1703 | 5006,5289 1704 | 5007,5290 1705 | 5008,5291 1706 | 5009,5292 1707 | 5010,5293 1708 | 5011,5294 1709 | 5012,5295 1710 | 5013,5296 1711 | 5014,5297 1712 | 5015,5298 1713 | 5016,5299 1714 | 5017,5300 1715 | 5018,5301 1716 | 5019,5302 1717 | 5020,5303 1718 | 5021,5304 1719 | 5022,5305 1720 | 5023,5306 1721 | 5024,5307 1722 | 5025,5308 1723 | 5026,5309 1724 | 5027,5310 1725 | 5028,5311 1726 | 5029,5312 1727 | 5030,5313 1728 | 5031,5314 1729 | 5032,5315 1730 | 5033,5316 1731 | 5034,5317 1732 | 5035,5318 1733 | 5036,5319 1734 | 5037,5320 1735 | 5038,5321 1736 | 5039,5322 1737 | 5040,5323 1738 | 5041,5324 1739 | 5042,5325 1740 | 5043,5326 1741 | 5044,5327 1742 | 5045,5328 1743 | 5046,5329 1744 | 5047,5330 1745 | 5048,5331 1746 | 5049,5332 1747 | 5050,5333 1748 | 5051,5334 1749 | 5052,5335 1750 | 5053,5336 1751 | 5054,5337 1752 | 5055,5338 1753 | 5056,5339 1754 | 5057,5340 1755 | 5058,5341 1756 | 5059,5342 1757 | 5060,5343 1758 | 5061,5344 1759 | 5062,5345 1760 | 5063,5346 1761 | 5064,5347 1762 | 5065,5348 1763 | 5066,5349 1764 | 5067,5350 1765 | 5068,5351 1766 | 5069,5352 1767 | 5070,5353 1768 | 5071,5354 1769 | 5072,5355 1770 | 5073,5356 1771 | 5074,5357 1772 | 5075,5359 1773 | 5076,5360 1774 | 5077,5361 1775 | 5078,5362 1776 | 5079,5363 1777 | 5080,5364 1778 | 5081,5365 1779 | 5082,5366 1780 | 5083,5367 1781 | 5084,5368 1782 | 5085,5369 1783 | 5086,5370 1784 | 5087,5372 1785 | 5088,5373 1786 | 5089,5374 1787 | 5090,5375 1788 | 5091,5376 1789 | 5092,5377 1790 | 5093,5378 1791 | 5094,5379 1792 | 5095,5380 1793 | 5096,5381 1794 | 5097,5382 1795 | 5098,5383 1796 | 5099,5384 1797 | 5100,5385 1798 | 5101,5386 1799 | 5102,5387 1800 | 5103,5388 1801 | 5104,5389 1802 | 5105,5390 1803 | 5106,5391 1804 | 5107,5392 1805 | 5108,5393 1806 | 5109,5394 1807 | 5110,5395 1808 | 5111,5396 1809 | 5112,5397 1810 | 5113,5398 1811 | 5114,5399 1812 | 5115,5400 1813 | 5116,5401 1814 | 5117,5402 1815 | 5118,5403 1816 | 5119,5404 1817 | 5120,5405 1818 | 5121,5406 1819 | 5122,5407 1820 | 5123,5408 1821 | 5124,5409 1822 | 5125,5410 1823 | 5126,5411 1824 | 5127,5412 1825 | 5128,5413 1826 | 5129,5414 1827 | 5130,5415 1828 | 5131,5416 1829 | 5132,5417 1830 | 5133,5418 1831 | 5134,5419 1832 | 5135,5420 1833 | 5136,5421 1834 | 5137,5422 1835 | 5138,5423 1836 | 5139,5424 1837 | 5140,5425 1838 | 5141,5426 1839 | 5142,5427 1840 | 5143,5428 1841 | 5144,5429 1842 | 5145,5430 1843 | 5146,5431 1844 | 5147,5432 1845 | 5148,5433 1846 | 5149,5434 1847 | 5150,5435 1848 | 5151,5436 1849 | 5152,5437 1850 | 5153,5438 1851 | 5154,5439 1852 | 5155,5440 1853 | 5156,5441 1854 | 5157,5442 1855 | 5158,5443 1856 | 5159,5444 1857 | 5160,5445 1858 | 5161,5446 1859 | 5162,5447 1860 | 5163,5448 1861 | 5164,5449 1862 | 5165,5450 1863 | 5166,5451 1864 | 5167,5452 1865 | 5168,5453 1866 | 5169,5454 1867 | 5170,5455 1868 | 5171,5456 1869 | 5172,5457 1870 | 5173,5458 1871 | 5174,5459 1872 | 5175,5460 1873 | 5176,5461 1874 | 5177,5462 1875 | 5178,5463 1876 | 5179,5464 1877 | 5180,5465 1878 | 5181,5466 1879 | 5182,5467 1880 | 5183,5468 1881 | 5184,5469 1882 | 5185,5470 1883 | 5186,5471 1884 | 5187,5472 1885 | 5188,5473 1886 | 5189,5474 1887 | 5190,5475 1888 | 5191,5476 1889 | 5192,5477 1890 | 5193,5478 1891 | 5194,5479 1892 | 5195,5480 1893 | 5196,5481 1894 | 5197,5482 1895 | 5198,5483 1896 | 5199,5484 1897 | 5200,5485 1898 | 5201,5486 1899 | 5202,5487 1900 | 5203,5488 1901 | 5204,5489 1902 | 5205,5490 1903 | 5206,5491 1904 | 5207,5492 1905 | 5208,5493 1906 | 5209,5494 1907 | 5210,5495 1908 | 5211,5496 1909 | 5212,5497 1910 | 5213,5498 1911 | 5214,5499 1912 | 5215,5500 1913 | 5216,5501 1914 | 5217,5502 1915 | 5218,5503 1916 | 5219,5504 1917 | 5220,5505 1918 | 5221,5506 1919 | 5222,5507 1920 | 5223,5508 1921 | 5224,5509 1922 | 5225,5510 1923 | 5226,5511 1924 | 5227,5512 1925 | 5228,5513 1926 | 5229,5514 1927 | 5230,5515 1928 | 5231,5516 1929 | 5232,5517 1930 | 5233,5518 1931 | 5234,5519 1932 | 5235,5520 1933 | 5236,5521 1934 | 5237,5522 1935 | 5238,5523 1936 | 5239,5524 1937 | 5240,5525 1938 | 5241,5526 1939 | 5242,5527 1940 | 5243,5528 1941 | 5244,5529 1942 | 5245,5530 1943 | 5246,5531 1944 | 5247,5532 1945 | 5248,5533 1946 | 5249,5534 1947 | 5250,5535 1948 | 5251,5536 1949 | 5252,5537 1950 | 5253,5538 1951 | 5254,5539 1952 | 5255,5540 1953 | 5256,5541 1954 | 5257,5542 1955 | 5258,5543 1956 | 5259,5544 1957 | 5260,5545 1958 | 5261,5546 1959 | 5262,5547 1960 | 5263,5548 1961 | 5264,5549 1962 | 5265,5550 1963 | 5266,5551 1964 | 5267,5552 1965 | 5268,5553 1966 | 5269,5554 1967 | 5270,5555 1968 | 5271,5556 1969 | 5272,5557 1970 | 5273,5558 1971 | 5274,5559 1972 | 5275,5560 1973 | 5276,5561 1974 | 5277,5562 1975 | 5278,5563 1976 | 5279,5564 1977 | 5280,5565 1978 | 5281,5566 1979 | 5282,5567 1980 | 5283,5568 1981 | 5284,5569 1982 | 5285,5570 1983 | 5286,5571 1984 | 5287,5572 1985 | 5288,5573 1986 | 5289,5574 1987 | 5290,5575 1988 | 5291,5579 1989 | 5292,8908 1990 | 5293,8909 1991 | 5294,8910 1992 | 5295,8911 1993 | 5296,8912 1994 | 5297,8913 1995 | 5298,8914 1996 | 5299,8915 1997 | 5300,8916 1998 | 5301,8917 1999 | 5302,8918 2000 | 5303,8920 2001 | 5304,8921 2002 | 5305,8922 2003 | 5306,8923 2004 | 5307,8924 2005 | 5308,8925 2006 | 5309,8926 2007 | 5310,8927 2008 | 5311,8928 2009 | 5312,8929 2010 | 5313,8930 2011 | 5314,8931 2012 | 5315,8932 2013 | 5316,8933 2014 | 5317,8934 2015 | 5318,8935 2016 | 5319,8936 2017 | 5320,8937 2018 | 5321,8938 2019 | 5322,8939 2020 | 5323,8940 2021 | 5324,8941 2022 | 5325,8942 2023 | 5326,8943 2024 | 5327,8944 2025 | 5328,8945 2026 | 5329,8946 2027 | 5330,8947 2028 | 5331,8948 2029 | 5332,8949 2030 | 5333,8950 2031 | 5334,8951 2032 | 5335,8952 2033 | 5336,8953 2034 | 5337,8954 2035 | 5338,8955 2036 | 5339,8956 2037 | 5340,8957 2038 | 5341,13958 2039 | 5342,13959 2040 | 5343,13960 2041 | 5344,13961 2042 | 5345,13968 2043 | 5346,13975 2044 | 5347,13978 2045 | 5348,13979 2046 | 5349,14266 2047 | -------------------------------------------------------------------------------- /GROA-ForC_integration/GROA-ForC mapping/Instructions for populating ForC history table from GROA.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/GROA-ForC_integration/GROA-ForC mapping/Instructions for populating ForC history table from GROA.docx -------------------------------------------------------------------------------- /GROA-ForC_integration/GROA-ForC mapping/README.md: -------------------------------------------------------------------------------- 1 | # Cook-Patton(CP)-ForC variable mapping - 2 | 3 | ForC-CP variable mapping is given in [this document](https://github.com/forc-db/ForC_private/blob/master/data%20to%20add/Cook-Patton/CP-ForC%20variable%20mapping.csv). It can be sorted by either CP or ForC variable order. 4 | 5 | ## Metadata for [mapping document](https://github.com/forc-db/ForC_private/blob/master/data%20to%20add/Cook-Patton/CP-ForC%20variable%20mapping.csv) 6 | field | def 7 | --- | --- 8 | CP order | field order in SRDB 9 | CP table | SRDB table 10 | CP field | SRDB col heading 11 | CP Description | SRDB variable description 12 | ForC order | order in ForC 13 | ForC table | ForC table 14 | ForC Column | ForC order within table 15 | ForC field | ForC col heading 16 | FOrC Description | ForC variable desc 17 | FOrC Storage.Type | ForC storage type 18 | ForC Variable.Codes | ForC variable codes (for categorical variables) 19 | ForC Units | ForC units, when applicable 20 | Value to assign - value entered | "value" - enter value as is; "value" included within formula - conversion to apply to numerical values, if any; string (in quotes) or numerical value- enter that value for all. In some cases, value to assign is dependent upon conditions (given in this field). 21 | Value to assign - missing values | value to enter when CP database ahs a missing value (NA). 22 | manual.review.needed | indicates when manual review of values will be needed following conversion to ForC format 23 | Clarifications needed | clarifications needed on the CP database 24 | notes | notes 25 | KAT action needed | required action by KAT 26 | ForC action needed | action required related to ForC database 27 | 28 | ## General guidance 29 | Each row in CP measurements will often correspond to one row in ForC tables. 30 | 1. Each record gets its own row in MEASUREMENTS 31 | 2. Each history event (for each plot; may be more than one plot per site) gets its own row in HISTORY. This is the most complex part. See [Instructions for populating ForC history table from CP.docx]() (to be created). 32 | 3. Each methodology / variable gets its own row in METHODOLOGY 33 | 4. Each site gets one row in SITES 34 | 5. Each citation gets one row in CITATIONS 35 | -------------------------------------------------------------------------------- /GROA-ForC_integration/GROA-ForC mapping/variable_name_conversion.csv: -------------------------------------------------------------------------------- 1 | GROA_variables.name,GROA_covariate,GROA_description,ForC_variable.name,units,ForC_description,ForC_notes 2 | aboveground_biomass,NA,,biomass_ag_OM,Mg ha-1,"Total aboveground live biomass. May include biomass of reproductive structures and understory biomass, if data are available. Dead wood excluded.","notes: ""excludes understory""" 3 | aboveground_biomass + belowground_biomass,NA,,biomass_OM,Mg ha-1,Total live biomass.,"notes: ""excludes understory""" 4 | aboveground_biomass + understory_biomass,NA,,biomass_ag_OM,Mg ha-1,"Total aboveground live biomass. May include biomass of reproductive structures and understory biomass, if data are available. Dead wood excluded.","notes: ""includes understory""" 5 | aboveground_biomass_stem,NA,just boles,NA,,, 6 | aboveground_biomass_woody,NA,,biomass_ag_woody_OM,Mg ha-1,Total aboveground structural (stem + branch) biomass,- 7 | aboveground_carbon,NA,,biomass_ag_C,Mg C ha-1,"Total carbon in aboveground live biomass. May include biomass of reproductive structures and understory biomass, if data are available. Dead wood excluded.","notes: ""excludes understory""" 8 | aboveground_carbon + belowground_carbon,NA,,biomass_C,Mg C ha-1,Total carbon in live biomass.,"notes: ""excludes understory""" 9 | aboveground_carbon + belowground_carbon + understory_carbon,NA,,biomass_C,Mg C ha-1,Total carbon in live biomass.,"notes: ""includes understory""" 10 | aboveground_carbon + litter_carbon,"forest floor + CWD, litter + dead woody debris","litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",total.ecosystem_2_C,Mg C ha-1,"Total ecosystem carbon in organic matter, including total biomass, deadwood, and organic layer but excluding soil organic carbon.","GROA component ""[component name]""" 11 | ,"litter, forest floor, CWD, FWD + CWD, FWD+CWD","litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",NA,,, 12 | aboveground_carbon + understory_carbon,NA,,biomass_ag_C,Mg C ha-1,"Total carbon in aboveground live biomass. May include biomass of reproductive structures and understory biomass, if data are available. Dead wood excluded.","notes: ""includes understory""" 13 | aboveground_carbon + understory_carbon + belowground_carbon + litter_carbon,NA,,total.ecosystem_2_C,Mg C ha-1,"Total ecosystem carbon in organic matter, including total biomass, deadwood, and organic layer but excluding soil organic carbon.","notes: ""includes understory""" 14 | aboveground_carbon_stem,NA,just boles,NA,,, 15 | belowground_biomass,NA,,biomass_root_OM,Mg ha-1,Total root biomass,- 16 | belowground_biomass_fine,NA,,biomass_root_fine_OM,Mg ha-1,"Total fine root biomass. Typical size cutoff (max.diameter_root) is 1-2 mm diameter, with preference given to max.diameter_root = 1 mm when there is an option.",- 17 | belowground_carbon,NA,,biomass_root_C,Mg C ha-1,Total carbon in root biomass,- 18 | litter_biomass,"litter, forest floor","litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",organic.layer_OM,Mg ha-1,Mass of litter/ organic layer/ forest floor,"GROA component ""[component name]""" 19 | ,CWD,"litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",deadwood_down_OM,Mg ha-1,Total mass of downed dead wood (coarse and sometimes fine woody debris),"GROA component ""[component name]""" 20 | ,"FWD + CWD, FWD+CWD","litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",deadwood_down_OM,Mg ha-1,Total mass of downed dead wood (coarse and sometimes fine woody debris),"GROA component ""[component name]""" 21 | ,"forest floor + CWD, litter + dead woody debris","litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",NA,,, 22 | litter_biomass + understory_biomass,NA,"litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",NA,,, 23 | litter_carbon,"litter, forest floor","litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",organic.layer_C,Mg C ha-1,Mass of litter/ organic layer/ forest floor,"GROA component ""[component name]""" 24 | ,CWD,"litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",deadwood_down_C,Mg C ha-1,Total carbon in downed dead wood (coarse and sometimes fine woody debris),"GROA component ""[component name]""" 25 | ,"FWD + CWD, FWD+CWD","litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",deadwood_down_C,Mg C ha-1,Total carbon in downed dead wood (coarse and sometimes fine woody debris),"GROA component ""[component name]""" 26 | ,"forest floor + CWD, litter + dead woody debris","litter = non-living organic material. May include litter, dead wood, or any combination thereof, as indicated in components covariate",NA,,, 27 | understory_biomass,NA,,biomass_ag_understory_OM,Mg ha-1,"Total understory biomass, where understory is most commonly defined as trees shorter than breast height.",- 28 | understory_carbon,NA,,biomass_ag_understory_C,Mg C ha-1,"Total carbon in understory biomass, where understory is most commonly defined as trees shorter than breast height.",- 29 | SOC,NA,,soil_C,Mg C ha-1,Soil organic carbon to specified depth in mineral soil,- 30 | soil_perC,NA,,secondary,soil_pC,%,- 31 | SOM_per,NA,,NA,,, 32 | CWD_carbon,NA,,deadwood_down_C,Mg C ha-1,Total carbon in downed dead wood (coarse and sometimes fine woody debris), 33 | aboveground_carbon + understory_carbon+CWD_carbon+litter_carbon,NA,,total.ecosystem_2_C,Mg C ha-1,"Total ecosystem carbon in organic matter, including total biomass, deadwood, and organic layer but excluding soil organic carbon.", 34 | aboveground_carbon + CWD_carbon + litter_carbon,NA,,total.ecosystem_2_C,Mg C ha-1,"Total ecosystem carbon in organic matter, including total biomass, deadwood, and organic layer but excluding soil organic carbon.", 35 | litter_biomass + CWD_biomass,NA,,NA,,, 36 | CWD_biomass,NA,,deadwood_down_OM,Mg ha-1,Total mass of downed dead wood (coarse and sometimes fine woody debris), 37 | CWD_carbon + litter_carbon,NA,,NA,,, 38 | litter_carbon + CWD_carbon,NA,,NA,,, -------------------------------------------------------------------------------- /GROA-ForC_integration/GROA.Rproj: -------------------------------------------------------------------------------- 1 | Version: 1.0 2 | 3 | RestoreWorkspace: Default 4 | SaveWorkspace: Default 5 | AlwaysSaveHistory: Default 6 | 7 | EnableCodeIndexing: Yes 8 | UseSpacesForTab: Yes 9 | NumSpacesForTab: 2 10 | Encoding: UTF-8 11 | 12 | RnwWeave: Sweave 13 | LaTeX: pdfLaTeX 14 | -------------------------------------------------------------------------------- /GROA-ForC_integration/Readme.md: -------------------------------------------------------------------------------- 1 | # GROA - ForC integration project 2 | 3 | This folder contains files relevant to the integration of the GROA database with the global forest C database ([ForC](https://forc-db.github.io/)), housed [here on GitHub](https://github.com/forc-db/ForC). 4 | 5 | Materials include the following: 6 | 7 | - [additional_GROA_files](https://github.com/forc-db/GROA/tree/master/GROA-ForC_integration/additional_GROA_files)- Files generated by Susan Cook-Patton's team for the sake of integration with ForC. 8 | - [GROA-ForC mapping](https://github.com/forc-db/GROA/tree/master/GROA-ForC_integration/GROA-ForC%20mapping)- Original instructions for mapping between GROA and ForC. Modifications to the original plan are not necessarily recorded in this document, but would be discussed in (closed) issues. 9 | - [scripts](https://github.com/forc-db/GROA/tree/master/GROA-ForC_integration/scripts)- scripts for merging GROA into ForC. 10 | - [new_data](https://github.com/forc-db/GROA/tree/master/GROA-ForC_integration/new_data)- GROA data that is not contained in ForC, including potential duplicates. 11 | - [Duplicates_processing](https://github.com/forc-db/GROA/tree/master/GROA-ForC_integration/Duplicates_processing) - Records from manual review of potential duplicates. 12 | -------------------------------------------------------------------------------- /GROA-ForC_integration/additional_GROA_files/ForC and GROA comparison.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/GROA-ForC_integration/additional_GROA_files/ForC and GROA comparison.csv -------------------------------------------------------------------------------- /GROA-ForC_integration/additional_GROA_files/ReadMe.md: -------------------------------------------------------------------------------- 1 | - ForC and GROA comparison.csv- File comparing the papers within GROA to the papers in ForCdb. [File is old version/ not comprehensive](https://github.com/forc-db/GROA/issues/21#issuecomment-634364764). 2 | 3 | - soiltosurface.csv - if I am remembering correctly, we generated the soiltosurface.csv to be consistent with ForCdb. (See [issue #22](https://github.com/forc-db/GROA/issues/22#issuecomment-634364210)). 4 | -------------------------------------------------------------------------------- /GROA-ForC_integration/new_data/GROA_sites.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/GROA-ForC_integration/new_data/GROA_sites.csv -------------------------------------------------------------------------------- /GROA-ForC_integration/new_data/new_CITATIONS.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/GROA-ForC_integration/new_data/new_CITATIONS.csv -------------------------------------------------------------------------------- /GROA-ForC_integration/new_data/new_ForC_simplified.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/GROA-ForC_integration/new_data/new_ForC_simplified.csv -------------------------------------------------------------------------------- /GROA-ForC_integration/new_data/new_HISTORY.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/GROA-ForC_integration/new_data/new_HISTORY.csv -------------------------------------------------------------------------------- /GROA-ForC_integration/new_data/new_MEASUREMENTS.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/GROA-ForC_integration/new_data/new_MEASUREMENTS.csv -------------------------------------------------------------------------------- /GROA-ForC_integration/new_data/new_PLOTS.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/GROA-ForC_integration/new_data/new_PLOTS.csv -------------------------------------------------------------------------------- /GROA-ForC_integration/new_data/new_SITES.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/GROA-ForC_integration/new_data/new_SITES.csv -------------------------------------------------------------------------------- /GROA-ForC_integration/new_data/potential_duplicates/potential.duplicate.records.csv: -------------------------------------------------------------------------------- 1 | "From","measurement.ID","sites.sitename","plot.name","stand.age","citation.ID","variable.name","mean","GROA.measurement.ID" 2 | "ForC",14044,"Subtropical broad-leaved evergreen forest chronosequence","Forest recovery following clear-cut.2y","2","Li_1999_ssit","biomass_ag_OM",20.0612,NA 3 | "GROA",3663,"Subtropical broad-leaved evergreen forest chronosequence","2757","2","Li_1999_ssit","biomass_ag_OM",4.5,3663 4 | "ForC",14042,"Subtropical broad-leaved evergreen forest chronosequence","Forest recovery following clear-cut.10y","10","Li_1999_ssit","biomass_ag_OM",47.806,NA 5 | "GROA",3665,"Subtropical broad-leaved evergreen forest chronosequence","2758","10","Li_1999_ssit","biomass_ag_OM",15.3,3665 6 | "ForC",14043,"Subtropical broad-leaved evergreen forest chronosequence","Forest recovery following clear-cut.25y","25","Li_1999_ssit","biomass_ag_OM",117.839,NA 7 | "GROA",3667,"Subtropical broad-leaved evergreen forest chronosequence","2759","25","Li_1999_ssit","biomass_ag_OM",89.3,3667 8 | "ForC",14045,"Subtropical broad-leaved evergreen forest chronosequence","Forest recovery following clear-cut.40y","40","Li_1999_ssit","biomass_ag_OM",85.0696,NA 9 | "GROA",13692,"Subtropical broad-leaved evergreen forest chronosequence","9782","40","Li_1999_ssit","biomass_ag_OM",70.8,13692 10 | "ForC",14046,"Subtropical broad-leaved evergreen forest chronosequence","Forest recovery following clear-cut.60y","60","Li_1999_ssit","biomass_ag_OM",95.7493,NA 11 | "GROA",13694,"Subtropical broad-leaved evergreen forest chronosequence","9784","60","Li_1999_ssit","biomass_ag_OM",83.6,13694 12 | -------------------------------------------------------------------------------- /GROA-ForC_integration/new_data/potential_duplicates/potential.duplicate.sites.csv: -------------------------------------------------------------------------------- 1 | "From","site.ID","sites.sitename","network","alt.names","super.site","city","state","country","lat","lon","masl","geography.notes","mat","min.temp","max.temp","map","climate.notes","soil.texture","sand","silt","clay","soil.classification","soil.notes","hydrology.notes","site.notes","geographic.area","biogeog","Koeppen","FAO.ecozone","site.ID.v1","measurement.refs","site.ref","ref.notes","lacks.info.from.ori.pub","loaded.from","loaded.by","potential_duplicate_group","potential_duplicate_group_parsed","confirmed.unique","potential.duplicates.manual","duplicate.notes","NEW_RECORD","GROA.site.ID","OLD_RECORD" 2 | "ForC",862,"Kambja",NA,NA,"","NAC","Polva","Estonia",58.05,27.017,"NAC",NA,"5.4","NAC","NAC","675",NA,"sandy loam","NAC","NAC","NAC","Albeluvisol","Albeluvisol",NA,NA,"371","Palearctic","Dfb","Temperate continental forest",NA,"Uri_2012_bpac",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 3 | "GROA",3821,"Kambja",NA,NA,NA,"NAC","","Estonia",58.233333,26.733333,"NAC",NA,"NAC","NAC","NAC","NAC",NA,"sandy loam","NaN","NaN","NaN","Glossic-Podzoluviol",NA,NA,NA,NA,NA,NA,NA,NA,"Aosaar_2016_bpan",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,3821,FALSE 4 | "ForC",596,"Fazenda Vitoria",NA,NA,"","Paragominas","Para","Brazil",-2.983,-47.533,"NAC",NA,"25.95","NAC","NAC","1800",NA,"clay","NAC","NAC","NAC","Latosol","Kaolinitic Yellow Latosols.","NAC",NA,"252","Neotropics","Am","Tropical rainforest","92","Davidson_2004_napl",NA,NA,NA,NA,NA,121,"1",NA,NA,"",FALSE,NA,NA 5 | "GROA",286,"Fazenda Vitoria",NA,NA,NA,"NAC","Para","Brazil",-2.983333,-47.516667,"NAC",NA,"NAC","NAC","NAC","1800",NA,"6.19.75","NaN","NaN","NaN","Latosols",NA,NA,NA,NA,NA,NA,NA,NA,"Markewitz_2004_nlar; de Camargo_1999_scdi; Siddique_2010_napa; Davidson_2004_napl",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,286,FALSE 6 | "ForC",1555,"S5",NA,NA,NA,"Co Ma","Son La","Vietnam",21.383,103.649,"1300",NA,"21.07","14","22","1277",NA,"NAC","NAC","NAC","NAC","Ferralic Acrisols","In this area, the dominant soil type is Ferralic Acrilsols, acidic soils with low base saturation and poor nutrient content. Humic Acrisols and Rhodic Ferralsols are also found occasionally.","NAC",NA,"664","IndoMalay","Cwa","Tropical mountain system","389","Tran_2010_rpoa",NA,NA,NA,NA,NA,262,"1","1",NA,"",FALSE,NA,NA 7 | "GROA",3577,"S5",NA,NA,NA,"NAC","","China",33.586389,107.849722,"1269",NA,"11.8","NAC","NAC","1075",NA,"NAC","NAC","NAC","NAC","NAC",NA,NA,NA,NA,NA,NA,NA,NA,NA,NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,3577,FALSE 8 | "ForC",87,"Arroyo Negro",NA,NA,"","Yucatan","Campeche","Mexico",17.883,-89.283,"NAC",NA,"25","NAC","NAC","1418",NA,"NAC","NAC","NAC","NAC","NAC","Regionally, soils are shallow, calcareous, and highly permeable due to organic matter content and under- lying limestone bedrock.","NAC",NA,"44","Neotropics","Aw","Tropical moist forest","338","Read_2003_robf",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 9 | "GROA",295,"Arroyo Negro",NA,NA,NA,"NAC","Campeche","Mexico",17.883333,-89.283333,"180",NA,"25","NAC","NAC","1400",NA,"45.30.26","NaN","NaN","NaN","Lithosol-redzina",NA,NA,NA,NA,NA,NA,NA,NA,"Eaton_2009_locs; Read_2003_robf",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,295,FALSE 10 | "ForC",1324,"Nicolas Bravo",NA,NA,"","Yucatan","Quintana Roo","Mexico",18.45,-88.93,"NAC",NA,"25","NAC","NAC","1114",NA,"NAC","NAC","NAC","NAC","NAC","Regionally, soils are shallow, calcareous, and highly permeable due to organic matter content and under- lying limestone bedrock.","NAC",NA,"561","Neotropics","Aw","Tropical moist forest","366","Read_2003_robf",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 11 | "GROA",294,"Nicolas Bravo",NA,NA,NA,"NAC","Quintana Roo","Mexico",18.45,-88.933333,"120",NA,"25","NAC","NAC","1150",NA,"35.35.30","NaN","NaN","NaN","Lithosol-redzina",NA,NA,NA,NA,NA,NA,NA,NA,"Eaton_2009_locs; Read_2003_robf",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,294,FALSE 12 | "ForC",563,"El Refugio",NA,NA,"","Yucatan","Campeche","Mexico",18.816,-89.383,"NAC",NA,"25","NAC","NAC","892",NA,"NAC","NAC","NAC","NAC","NAC","Regionally, soils are shallow, calcareous, and highly permeable due to organic matter content and under- lying limestone bedrock.","NAC",NA,"238","Neotropics","Aw","Tropical moist forest","380","Read_2003_robf",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 13 | "GROA",293,"El Refugio",NA,NA,NA,"NAC","Campeche","Mexico",18.816667,-89.383333,"250",NA,"25","NAC","NAC","890",NA,"30.36.35","NaN","NaN","NaN","Lithosol-redzina",NA,NA,NA,NA,NA,NA,NA,NA,"Eaton_2009_locs; Lawrence_2002_cifb; Read_2003_robf",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,293,FALSE 14 | "ForC",1333,"Nizanda",NA,NA,"","NAC","Oaxaca","Mexico",16.664,-95.497,"NAC",NA,"NAC","NAC","NAC","893",NA,"NAC","NAC","NAC","NAC","NAC",NA,"NAC",NA,"563","Neotropics","Aw","Tropical dry forest","1364","Poorter_2015_decs",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 15 | "GROA",40,"Nizanda",NA,NA,NA,"NAC","Oaxaca","Mexico",16.658333,-95.111111,"250",NA,"26","NAC","NAC","900",NA,"","NaN","NaN","NaN","Lithosols",NA,NA,NA,NA,NA,NA,NA,NA,"Lebrija-Trejos_2008_scar",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,40,FALSE 16 | "ForC",526,"Doi Inthanon",NA,NA,"","NAC","Chiang Mai","Thailand",18.5248,98.4965,"NAC",NA,"20.9","NAC","NAC","1908",NA,"NAC","NAC","NAC","NAC","NAC",NA,NA,"Evergreen forest","220","IndoMalay","Aw","Tropical mountain system","386","Liu_2014_htpa",NA,NA,NA,"Liu_2014_htpa",NA,110,"1",NA,NA,"",FALSE,NA,NA 17 | "GROA",2403,"Doi Inthanon",NA,NA,NA,"NAC","Chiang Mai Province","Thailand",18.55,98.516667,"1208",NA,"21.1","NAC","NAC","1908",NA,"sandy loamy","NaN","NaN","NaN","NAC",NA,NA,NA,NA,NA,NA,NA,NA,"Fukushima_2008_sfsa",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,2403,FALSE 18 | "ForC",1168,"Manaus BR-174",NA,NA,"","Manaus","Amazonas","Brazil",-2.45,-60.05,"100",NA,"NAC","NAC","NAC","NAC","mild dry season Aug-Oct","clay","NAC","NAC","NAC","Oxisol","plateau soil is classified as dystrophic, isohyperthermic, clayey kaolinitic, Hapludox. Slope soils are Ultisols and valley bottoms are Spodosols","NAC",NA,"68","Neotropics","Af","Tropical rainforest","103","Feldpausch_2004_cana",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 19 | "GROA",314,"Manaus BR-174",NA,NA,NA,"NAC","Amazonas","Brazil",-2.45,-60.05,"100",NA,"26.7","NAC","NAC","2200",NA,"NAC","NAC","NAC","NAC","Ferrasols",NA,NA,NA,NA,NA,NA,NA,NA,"Feldpausch_2007_sfgd",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,314,FALSE 20 | "ForC",563,"El Refugio",NA,NA,"","Yucatan","Campeche","Mexico",18.816,-89.383,"NAC",NA,"25","NAC","NAC","892",NA,"NAC","NAC","NAC","NAC","NAC","Regionally, soils are shallow, calcareous, and highly permeable due to organic matter content and under- lying limestone bedrock.","NAC",NA,"238","Neotropics","Aw","Tropical moist forest","380","Read_2003_robf",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 21 | "GROA",2417,"El Refugio",NA,NA,NA,"NAC","Campeche","Mexico",18.816667,-89.45,"NAC",NA,"25","NAC","NAC","900",NA,"30.36.35","NaN","NaN","NaN","Rendzina",NA,NA,NA,NA,NA,NA,NA,NA,"Eaton_2006_wdsa",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,2417,FALSE 22 | "ForC",2128,"Manaus",NA,NA,NA,"Manaus","NAC","Brazil",-4,-60,"90",NA,"27.2","NAC","NAC","1771",NA,"NAC","NAC","NAC","NAC","NAC","Pale yellow latosol","Well drained",NA,"NAC","Neotropic","Am","Tropical rainforest",NA,"DeAngelis_1981_pofe","DeAngelis_1981_pofe","DeAngelis et al 1981 IBP_19,",NA,"DeAngelis_1981_pofe","Becky Banbury Morgan",0,"0","",NA,"",FALSE,NA,NA 23 | "ForC",2180,"Manaus",NA,NA,NA,"NAC","NAC","Brazil",-2.37,-60.09,"NAC",NA,"25","NAC","NAC","2200",NA,"NAC","NAC","NAC","NAC","NAC","NAC",NA,NA,"NAC","NAC","Af","Tropical rainforest",NA,"Nardoto_2008_utio","Nardoto_2008_utio",NA,NA,"Taylor_2017_tari","Becky Banbury Morgan",0,"0","",NA,"",FALSE,NA,NA 24 | "GROA",291,"Manaus",NA,NA,NA,"NAC","Amazonas","Brazil",-3,-60,"135",NA,"26.7","NAC","NAC","2180",NA,"","NaN","NaN","NaN","Oxisols",NA,NA,NA,NA,NA,NA,NA,NA,"Gehring_2005_rosf",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,291,FALSE 25 | "ForC",596,"Fazenda Vitoria",NA,NA,"","Paragominas","Para","Brazil",-2.983,-47.533,"NAC",NA,"25.95","NAC","NAC","1800",NA,"clay","NAC","NAC","NAC","Latosol","Kaolinitic Yellow Latosols.","NAC",NA,"252","Neotropics","Am","Tropical rainforest","92","Davidson_2004_napl",NA,NA,NA,NA,NA,121,"1",NA,NA,"",FALSE,NA,NA 26 | "GROA",286,"Fazenda Vitoria",NA,NA,NA,"NAC","Para","Brazil",-2.983333,-47.516667,"<200",NA,"25.95","NAC","NAC","1800",NA,"6.19.75","NaN","NaN","NaN","Oxisols",NA,NA,NA,NA,NA,NA,NA,NA,"Markewitz_2004_nlar; de Camargo_1999_scdi; Siddique_2010_napa; Davidson_2004_napl",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,286,FALSE 27 | "ForC",1168,"Manaus BR-174",NA,NA,"","Manaus","Amazonas","Brazil",-2.45,-60.05,"100",NA,"NAC","NAC","NAC","NAC","mild dry season Aug-Oct","clay","NAC","NAC","NAC","Oxisol","plateau soil is classified as dystrophic, isohyperthermic, clayey kaolinitic, Hapludox. Slope soils are Ultisols and valley bottoms are Spodosols","NAC",NA,"68","Neotropics","Af","Tropical rainforest","103","Feldpausch_2004_cana",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 28 | "GROA",314,"Manaus BR-174",NA,NA,NA,"NAC","Amazonas","Brazil",-2.45,-60.05,"100",NA,"26.7","NAC","NAC","2200",NA,"NAC","NAC","NAC","NAC","Oxisols",NA,NA,NA,NA,NA,NA,NA,NA,"Feldpausch_2007_sfgd",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,314,FALSE 29 | "ForC",596,"Fazenda Vitoria",NA,NA,"","Paragominas","Para","Brazil",-2.983,-47.533,"NAC",NA,"25.95","NAC","NAC","1800",NA,"clay","NAC","NAC","NAC","Latosol","Kaolinitic Yellow Latosols.","NAC",NA,"252","Neotropics","Am","Tropical rainforest","92","Davidson_2004_napl",NA,NA,NA,NA,NA,121,"1",NA,NA,"",FALSE,NA,NA 30 | "GROA",286,"Fazenda Vitoria",NA,NA,NA,"NAC","Para","Brazil",-2.983333,-47.516667,"200",NA,"NAC","NAC","NAC","1803",NA,"6.19.75","NaN","NaN","NaN","Oxisols",NA,NA,NA,NA,NA,NA,NA,NA,"Markewitz_2004_nlar; de Camargo_1999_scdi; Siddique_2010_napa; Davidson_2004_napl",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,286,FALSE 31 | "ForC",1050,"Los Tuxtlas",NA,NA,"","NAC","Veracruz","Mexico",18.58,-95.08,"NAC",NA,"27","NAC","NAC","4700",NA,"NAC","NAC","NAC","NAC","NAC",NA,"NAC",NA,"442","Neotropics","Am","Tropical rainforest","367","Poorter_2015_decs; Hughes_2000_eiod",NA,NA,NA,NA,NA,208,"1",NA,NA,"needs review",FALSE,NA,NA 32 | "GROA",2261,"Los Tuxtlas",NA,NA,NA,"NAC","Veracruz","Mexico",18.583333,-95.083333,"NAC",NA,"27","NAC","NAC","4000",NA,"NAC","NAC","NAC","NAC","vitric Andosols",NA,NA,NA,NA,NA,NA,NA,NA,"Hughes_1999_bcan; Jaramillo_2003_rbac",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,2261,FALSE 33 | "ForC",87,"Arroyo Negro",NA,NA,"","Yucatan","Campeche","Mexico",17.883,-89.283,"NAC",NA,"25","NAC","NAC","1418",NA,"NAC","NAC","NAC","NAC","NAC","Regionally, soils are shallow, calcareous, and highly permeable due to organic matter content and under- lying limestone bedrock.","NAC",NA,"44","Neotropics","Aw","Tropical moist forest","338","Read_2003_robf",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 34 | "GROA",295,"Arroyo Negro",NA,NA,NA,"NAC","Campeche","Mexico",17.883333,-89.283333,"180",NA,"25","NAC","NAC","1418",NA,"45.30.26","NaN","NaN","NaN","NAC",NA,NA,NA,NA,NA,NA,NA,NA,"Eaton_2009_locs; Read_2003_robf",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,295,FALSE 35 | "ForC",1324,"Nicolas Bravo",NA,NA,"","Yucatan","Quintana Roo","Mexico",18.45,-88.93,"NAC",NA,"25","NAC","NAC","1114",NA,"NAC","NAC","NAC","NAC","NAC","Regionally, soils are shallow, calcareous, and highly permeable due to organic matter content and under- lying limestone bedrock.","NAC",NA,"561","Neotropics","Aw","Tropical moist forest","366","Read_2003_robf",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 36 | "GROA",294,"Nicolas Bravo",NA,NA,NA,"NAC","Quintana Roo","Mexico",18.45,-88.933333,"120",NA,"25","NAC","NAC","1114",NA,"35.35.30","NaN","NaN","NaN","NAC",NA,NA,NA,NA,NA,NA,NA,NA,"Eaton_2009_locs; Read_2003_robf",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,294,FALSE 37 | "ForC",563,"El Refugio",NA,NA,"","Yucatan","Campeche","Mexico",18.816,-89.383,"NAC",NA,"25","NAC","NAC","892",NA,"NAC","NAC","NAC","NAC","NAC","Regionally, soils are shallow, calcareous, and highly permeable due to organic matter content and under- lying limestone bedrock.","NAC",NA,"238","Neotropics","Aw","Tropical moist forest","380","Read_2003_robf",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 38 | "GROA",293,"El Refugio",NA,NA,NA,"NAC","Campeche","Mexico",18.816667,-89.383333,"250",NA,"25","NAC","NAC","892",NA,"30.36.35","NaN","NaN","NaN","NAC",NA,NA,NA,NA,NA,NA,NA,NA,"Eaton_2009_locs; Lawrence_2002_cifb; Read_2003_robf",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,293,FALSE 39 | "ForC",1138,"Luquillo",NA,NA,"Luquillo","NAC","Puerto Rico","United States of America",18.32,-65.82,"170",NA,"23","NAC","NAC","1100",NA,"clay loam","NAC","NAC","NAC","NAC",NA,"NAC",NA,"81","Neotropics","Am","Tropical rainforest","358","Luyssaert_2007_cbob","Lugo_1992_cott",NA,NA,"Luyssaert_2007_cbob",NA,38,"1","NAC",NA,"",FALSE,NA,NA 40 | "GROA",10,"Luquillo",NA,NA,NA,"NAC","Puerto Rico","United States",18.34,-65.76,"305",NA,"NAC","NAC","NAC","2660",NA,"","NaN","NaN","NaN","ultisols",NA,NA,NA,NA,NA,NA,NA,NA,"Aide_2000_fria",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,10,FALSE 41 | "ForC",1050,"Los Tuxtlas",NA,NA,"","NAC","Veracruz","Mexico",18.58,-95.08,"NAC",NA,"27","NAC","NAC","4700",NA,"NAC","NAC","NAC","NAC","NAC",NA,"NAC",NA,"442","Neotropics","Am","Tropical rainforest","367","Poorter_2015_decs; Hughes_2000_eiod",NA,NA,NA,NA,NA,208,"1",NA,NA,"needs review",FALSE,NA,NA 42 | "GROA",2261,"Los Tuxtlas",NA,NA,NA,"NAC","Veracruz","Mexico",18.583333,-95.083333,"200",NA,"27","NAC","NAC","4000",NA,"NAC","NAC","NAC","NAC","Andosol",NA,NA,NA,NA,NA,NA,NA,NA,"Hughes_1999_bcan; Jaramillo_2003_rbac",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,2261,FALSE 43 | "ForC",596,"Fazenda Vitoria",NA,NA,"","Paragominas","Para","Brazil",-2.983,-47.533,"NAC",NA,"25.95","NAC","NAC","1800",NA,"clay","NAC","NAC","NAC","Latosol","Kaolinitic Yellow Latosols.","NAC",NA,"252","Neotropics","Am","Tropical rainforest","92","Davidson_2004_napl",NA,NA,NA,NA,NA,121,"1",NA,NA,"",FALSE,NA,NA 44 | "GROA",286,"Fazenda Vitoria",NA,NA,NA,"NAC","Para","Brazil",-2.983333,-47.516667,"NAC",NA,"NAC","NAC","NAC","1750",NA,"6.19.75","NaN","NaN","NaN","Oxisols",NA,NA,NA,NA,NA,NA,NA,NA,"Markewitz_2004_nlar; de Camargo_1999_scdi; Siddique_2010_napa; Davidson_2004_napl",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,286,FALSE 45 | "ForC",1533,"Rio Sabana abandoned pastures chronosequence",NA,NA,"","NAC","Puerto Rico","United States of America",18.33,-65.73,"125","coords obtained from comparing map in paper with google maps","25","NAC","NAC","3000",NA,"clay","NAC","NAC","NAC","Ultisol","Primary Ultisols in the Zarzal-Cristal complex.","NAC",NA,"81","Neotropics","Am","Tropical rainforest","361","Aide_1995_fria",NA,NA,NA,NA,NA,89,"1",NA,NA,"",FALSE,NA,NA 46 | "GROA",284,"Rio Sabana abandoned pastures chronosequence",NA,NA,NA,"NAC","Puerto Rico","United States",18.33,-65.73,"125",NA,"NAC","NAC","NAC","3162",NA,"","NaN","NaN","NaN","NAC",NA,NA,NA,NA,NA,NA,NA,NA,"AIDE_1995_fria",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,284,FALSE 47 | "ForC",1530,"Rio Mameyes abandoned pastures chronosequence",NA,NA,"","NAC","Puerto Rico","United States of America",18.334,-65.7553,"125","coords obtained from comparing map in paper with google maps","25","NAC","NAC","3000",NA,"clay","NAC","NAC","NAC","Ultisol","Primary Ultisols in the Humatas series","NAC",NA,"81","Neotropics","Am","Tropical rainforest","362","Aide_1995_fria",NA,NA,NA,NA,NA,89,"1",NA,NA,"",FALSE,NA,NA 48 | "GROA",285,"Rio Mameyes abandoned pastures chronosequence",NA,NA,NA,"NAC","Puerto Rico","United States",18.334,-65.7553,"125",NA,"NAC","NAC","NAC","3162",NA,"","NaN","NaN","NaN","NAC",NA,NA,NA,NA,NA,NA,NA,NA,"AIDE_1995_fria",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,285,FALSE 49 | "ForC",879,"Kings County Hardwood Forest Chronosequence",NA,NA,"","NAC","Nova Scotia","Canada",44.833333,-64.783333,"NAC",NA,"6.08","NAC","NAC","1107",NA,"loam","NAC","NAC","NAC","Entisol","All of the sites are well drained, with gentle slopes, and with a shallow Gibraltar soil (Coarse-loamy, mixed, active, nonacid, mesic Mollic Udifluvents) derived from a stony-sandy till composed largely of granitic minerals.",NA,NA,"382","Nearctic","Dfb","Temperate mountain system",NA,"Crowell_1994_vdia",NA,NA,NA,"Anderson_2006_toba",NA,0,"0",NA,NA,"",FALSE,NA,NA 50 | "GROA",3507,"Kings County Hardwood Forest Chronosequence",NA,NA,NA,"NAC","Nova Scotia","Canada",44.833333,-64.783333,"NAC",NA,"NAC","NAC","NAC","1107",NA,"sandy","NaN","NaN","NaN","Udifluvents",NA,NA,NA,NA,NA,NA,NA,NA,"CROWELL_1994_vdia",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,3507,FALSE 51 | "ForC",1142,"Luquillo Experimental Forest",NA,NA,"Luquillo","El Verde","Puerto Rico","United States of America",18.3,-65.8,"500","lat-long estimated from map in paper and google maps; more precise value may be possible. See Luyssaert?","22.3","NAC","NAC","3760",NA,"clay","NAC","NAC","NAC","NAC",NA,"NAC","Secondary tabonuco forest","81","Neotropics","Am","Tropical mountain system","356","Crow_1980_arca",NA,NA,NA,"Anderson_2006_toba",NA,38,"1,2","NAC",NA,"",FALSE,NA,NA 52 | "GROA",100,"Luquillo Experimental Forest",NA,NA,NA,"NAC","Puerto Rico","United States",18.3,-65.847222,"284",NA,"22.3","NAC","NAC","3523",NA,"25.41.35","NaN","NaN","NaN","ultisols/oxisols",NA,NA,NA,NA,NA,NA,NA,NA,"LUGO_1992_cott",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,100,FALSE 53 | "ForC",1142,"Luquillo Experimental Forest",NA,NA,"Luquillo","El Verde","Puerto Rico","United States of America",18.3,-65.8,"500","lat-long estimated from map in paper and google maps; more precise value may be possible. See Luyssaert?","22.3","NAC","NAC","3760",NA,"clay","NAC","NAC","NAC","NAC",NA,"NAC","Secondary tabonuco forest","81","Neotropics","Am","Tropical mountain system","356","Crow_1980_arca",NA,NA,NA,"Anderson_2006_toba",NA,38,"1,2","NAC",NA,"",FALSE,NA,NA 54 | "GROA",3817,"Luquillo Experimental Forest",NA,NA,NA,"NAC","Puerto Rico","United States",18.316667,-65.816667,"350",NA,"NAC","NAC","NAC","NAC",NA,"25.41.35","NaN","NaN","NaN","ultisols",NA,NA,NA,NA,NA,NA,NA,NA,"CUEVAS_1991_aabo",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,3817,FALSE 55 | "ForC",85,"Araracuara",NA,NA,"","NAC","Amazonas","Colombia",-0.63,-72.37,"NAC",NA,"25.5","NAC","NAC","2998",NA,"NAC","NAC","NAC","NAC","NAC",NA,"NAC",NA,"42","Neotropics","Af","Tropical rainforest","131","Overman_1994_eorm",NA,NA,NA,"Keith_2009_rofb; Liu_2014_htpa",NA,0,"0",NA,NA,"",FALSE,NA,NA 56 | "GROA",59,"Araracuara",NA,NA,NA,"NAC","","Colombia",-0.616667,-72.45,"160",NA,"25.7","NAC","NAC","3059",NA,"silt loam to loamy sand","NaN","NaN","NaN","ultisols",NA,NA,NA,NA,NA,NA,NA,NA,"Vester_1998_taas",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,59,FALSE 57 | "ForC",370,"Chajul",NA,NA,"","NAC","Quiche","Mexico",16.017,-90.917,"NAC",NA,"NAC","NAC","NAC","2849",NA,"NAC","NAC","NAC","NAC","NAC",NA,"NAC",NA,"150","Neotropics","Aw","Tropical rainforest","1360","Poorter_2015_decs",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 58 | "GROA",61,"Chajul",NA,NA,NA,"NAC","Chiapas","Mexico",16.066667,-90.75,"207",NA,"24","NAC","NAC","3000",NA,"sand","NaN","NaN","NaN","NAC",NA,NA,NA,NA,NA,NA,NA,NA,"van Breugel_2006_cdde",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,61,FALSE 59 | "ForC",878,"Kibale National Park",NA,NA,"","NAC","Kamwenge","Uganda",0.45,30.425,"1500",NA,"NAC","NAC","NAC","1700",NA,"NAC","NAC","NAC","NAC","NAC",NA,"NAC",NA,"381","Afrotropics","As","Tropical rainforest","1230","Naughton-Treves_2002_fraf",NA,NA,NA,"Bonner_2013_amgc",NA,0,"0",NA,NA,"",FALSE,NA,NA 60 | "GROA",2350,"Kibale National Park",NA,NA,NA,"NAC","Kamwenge","Uganda",0.616667,30.425,"1500",NA,"NAC","NAC","NAC","1700",NA,"","NaN","NaN","NaN","NAC",NA,NA,NA,NA,NA,NA,NA,NA,"Naughton-Treves_2001_fraf",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,2350,FALSE 61 | "ForC",1531,"Rio Negro age sequence",NA,NA,"","San Carlos de Rio Negro","Amazonas","Venezuela",1.933333,-67.05,"119","4 km east of the village of San Carlos de Rio Negro.","26.88","NAC","NAC","3500",NA,"sandy","NAC","NAC","NAC","Oxisol","The topography consists of gently rolling hills which rise up to 50 m above the mean river level. The hill forests are never flooded and have soils consisting of a sandy horizon (from a few centimetres to 2 m in depth) over- lying a thick horizon composed of kaolinite clay and lateritic concretions. These soils are classified as Oxisols (United States 7th approximation) or Ferralsols (FAO classification). Both horizons are acid and highly weathered, and have low cation exchange capacity and high iron and aluminum content (Jordan 1982). Above the mineral soil is a mat of humus and roots which plays an important role in nutrient cycling (Jordan and Herrera 1981).","NAC",NA,"657","Neotropics","Af","Tropical rainforest","175","Uhl_1984_sand; Uhl_1987_fcsf","Jordan_1981_trfa; Jordan_1982_tnbo",NA,NA,NA,NA,259,"1,2,3,4",NA,NA,"needs review",FALSE,NA,NA 62 | "GROA",274,"Rio Negro age sequence",NA,NA,NA,"NAC","","Venezuela",1.933333,-67.05,"119",NA,"26.88","NAC","NAC","3500",NA,"sand","NaN","NaN","NaN","oxisols",NA,NA,NA,NA,NA,NA,NA,NA,"Uhl_1984_sand; Kauffman_1988_fitv",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,274,FALSE 63 | "ForC",1428,"Paragominas",NA,NA,"","Paragominas","Para","Brazil",-2.983333,-47.516667,"NI",NA,"24.1","NAC","NAC","1750",NA,"clay","NAC","NAC","NAC","Latosol","Kaolinic yellow latosols","NAC","Tropical evergreen","252","Neotropics","Am","Tropical rainforest","91","Trumbore_2006_dofr; Luyssaert_2007_cbob; Clark_2001_nppi; Clark_2013_ntfc; Malhi_2011_taoe","Clark_2001_nppi","Trumbore 1995; J. Chambers & D. Nepstad; pers. comm.",NA,NA,NA,121,"1",NA,NA,"",FALSE,NA,NA 64 | "ForC",2109,"Paragominas",NA,NA,NA,"NAC","Para","Brazil",-2.8,-47.52,"NAC",NA,"26.7","NAC","NAC","1750",NA,"NAC","NAC","NAC","NAC","NAC","NAC",NA,NA,"NAC","Neotropic","Am","Tropical rainforest",NA,"Trumbore_1995_bcoc","Trumbore_1995_bcoc",NA,NA,"Taylor_2017_tari","Becky Banbury Morgan",0,"0","",NA,"",FALSE,NA,NA 65 | "GROA",277,"Paragominas",NA,NA,NA,"NAC","Para","Brazil",-3,-47.5,"NAC",NA,"25.2","NAC","NAC","1750",NA,"clay","NaN","NaN","NaN","oxisols",NA,NA,NA,NA,NA,NA,NA,NA,"Buschbacher_1988_apie; Uhl_1988_apie",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,277,FALSE 66 | "ForC",1428,"Paragominas",NA,NA,"","Paragominas","Para","Brazil",-2.983333,-47.516667,"NI",NA,"24.1","NAC","NAC","1750",NA,"clay","NAC","NAC","NAC","Latosol","Kaolinic yellow latosols","NAC","Tropical evergreen","252","Neotropics","Am","Tropical rainforest","91","Trumbore_2006_dofr; Luyssaert_2007_cbob; Clark_2001_nppi; Clark_2013_ntfc; Malhi_2011_taoe","Clark_2001_nppi","Trumbore 1995; J. Chambers & D. Nepstad; pers. comm.",NA,NA,NA,121,"1",NA,NA,"",FALSE,NA,NA 67 | "ForC",2109,"Paragominas",NA,NA,NA,"NAC","Para","Brazil",-2.8,-47.52,"NAC",NA,"26.7","NAC","NAC","1750",NA,"NAC","NAC","NAC","NAC","NAC","NAC",NA,NA,"NAC","Neotropic","Am","Tropical rainforest",NA,"Trumbore_1995_bcoc","Trumbore_1995_bcoc",NA,NA,"Taylor_2017_tari","Becky Banbury Morgan",0,"0","",NA,"",FALSE,NA,NA 68 | "GROA",277,"Paragominas",NA,NA,NA,"NAC","Para","Brazil",-3,-47.5,"NAC",NA,"25.2","NAC","NAC","1750",NA,"clay","NaN","NaN","NaN","Oxisol/Ultisols",NA,NA,NA,NA,NA,NA,NA,NA,"Buschbacher_1988_apie; Uhl_1988_apie",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,277,FALSE 69 | "ForC",2018,"Yangambi",NA,NA,"","NAC","Orientale","Congo",0.77,24.44,"NAC",NA,"25.2333","NAC","NAC","1858",NA,"NAC","NAC","NAC","NAC","NAC",NA,"NAC",NA,"814","Afrotropics","Af","Tropical rainforest","139","Bartholemew_1953_mniu",NA,NA,NA,"Anderson_2006_toba",NA,0,"0",NA,NA,"",FALSE,NA,NA 70 | "GROA",255,"Yangambi",NA,NA,NA,"NAC","Orientale","Democratic Republic of Congo",0.77,24.44,"NAC",NA,"25.2","NAC","NAC","1858",NA,"","NaN","NaN","NaN","Latosolic",NA,NA,NA,NA,NA,NA,NA,NA,"Bartholomew_1953_mniu",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,255,FALSE 71 | "ForC",1161,"Mamiraua Sustainable Development Reserve",NA,NA,"","Manaus","Amazonas","Brazil",-2.799934,-64.883583,"NAC",NA,"NAC","NAC","NAC","3000",NA,"NAC","NAC","NAC","NAC","NAC",NA,"VARZEA FLOODPLAIN",NA,"496","Neotropics","Af","Tropical rainforest","93","Sch_ngart_2010_banp",NA,NA,NA,NA,NA,0,"0",NA,NA,"",FALSE,NA,NA 72 | "GROA",307,"Mamiraua Sustainable Development Reserve",NA,NA,NA,"NAC","Amazonas","Brazil",-2.799934,-64.88,"NAC",NA,"26.9","NAC","NAC","3000",NA,"","NaN","NaN","NaN","NAC",NA,NA,NA,NA,NA,NA,NA,NA,"Schongart_2010_banp",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,307,FALSE 73 | "ForC",1400,"Oregon Cascades 2 (cool temperate montane)",NA,NA,"","NAC","Oregon","United States of America",44,-122.5,"NAC",NA,"8.5","NAC","NAC","2300",NA,"NAC","NAC","NAC","NAC","NAC",NA,NA,NA,"594","Nearctic","Csb","Temperate mountain system",NA,"Means_1992_banc",NA,"Keith_2009_rofb; Liu_2014_htpa",NA,"Keith_2009_rofb; Liu_2014_htpa","Maria",0,"0",NA,NA,"potential duplicate: Oregon Cascades 1 & 2",FALSE,NA,NA 74 | "GROA",2393,"Oregon Cascades 2 (cool temperate montane)",NA,NA,NA,"NAC","Oregon","United States",44,-122.5,"1140",NA,"5.4","NAC","NAC","2730",NA,"clay loam","NaN","NaN","NaN","Spodosol",NA,NA,NA,NA,NA,NA,NA,NA,"Grier_1981_bdaa",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,2393,FALSE 75 | "ForC",1588,"San Carlos de Rio Negro abandoned slash-and-burn plots",NA,NA,"","NAC","Amazonas","Venezuela",1.93,-67.05,"NAC",NA,"26","NAC","NAC","3500","dry season Oct-March","NAC","NAC","NAC","NAC","NAC",NA,"NAC",NA,"657","Neotropics","Af","Tropical rainforest","1408","Kauffman_1988_fitv","Uhl_1984_sand",NA,NA,"Chao_2009_atdq",NA,259,"2",NA,NA,"needs review",FALSE,NA,NA 76 | "GROA",274,"San Carlos de Rio Negro abandoned slash-and-burn plots",NA,NA,NA,"NAC","","Venezuela",1.933333,-67.05,"NAC",NA,"26","NAC","NAC","3500",NA,"NAC","NAC","NAC","NAC","Oxisols",NA,NA,NA,NA,NA,NA,NA,NA,"Uhl_1984_sand; Kauffman_1988_fitv",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,274,FALSE 77 | "ForC",2008,"Y site",NA,NA,"","NAC","Oregon","United States of America",44.433,-121.567,"1188",NA,"7","NAC","NAC","552",NA,"NAC","NAC","NAC","NAC","NAC",NA,NA,NA,"366","Nearctic","Csb","Temperate mountain system",NA,"Law_2001_csaf",NA,NA,NA,"Bety-DB data download 4/10/2014 (Matlab output)",NA,228,"1,2,3,4,5,6,7,8,9,10,11",NA,NA,"",FALSE,NA,NA 78 | "GROA",2250,"Y site",NA,NA,NA,"NAC","Oregon","United States",44.433333,-121.566667,"1188",NA,"7.5","NAC","NAC","552",NA,"62.30.8","NaN","NaN","NaN","Ultic haploxeralfs",NA,NA,NA,NA,NA,NA,NA,NA,"Kelliher_2004_ltcm; Law_2001_csaf",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,2250,FALSE 79 | "ForC",1138,"Luquillo",NA,NA,"Luquillo","NAC","Puerto Rico","United States of America",18.32,-65.82,"170",NA,"23","NAC","NAC","1100",NA,"clay loam","NAC","NAC","NAC","NAC",NA,"NAC",NA,"81","Neotropics","Am","Tropical rainforest","358","Luyssaert_2007_cbob","Lugo_1992_cott",NA,NA,"Luyssaert_2007_cbob",NA,38,"1","NAC",NA,"",FALSE,NA,NA 80 | "GROA",3902,"Luquillo",NA,NA,NA,"NAC","Puerto Rico","United States",18.35,-65.916667,"325",NA,"23","NAC","NAC","2800",NA,"","NaN","NaN","NaN","ultisols",NA,NA,NA,NA,NA,NA,NA,NA,NA,NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,3902,FALSE 81 | "ForC",1138,"Luquillo",NA,NA,"Luquillo","NAC","Puerto Rico","United States of America",18.32,-65.82,"170",NA,"23","NAC","NAC","1100",NA,"clay loam","NAC","NAC","NAC","NAC",NA,"NAC",NA,"81","Neotropics","Am","Tropical rainforest","358","Luyssaert_2007_cbob","Lugo_1992_cott",NA,NA,"Luyssaert_2007_cbob",NA,38,"1","NAC",NA,"",FALSE,NA,NA 82 | "GROA",3902,"Luquillo",NA,NA,NA,"NAC","Puerto Rico","United States",18.35,-65.916667,"625",NA,"23","NAC","NAC","2800",NA,"","NaN","NaN","NaN","ultisols",NA,NA,NA,NA,NA,NA,NA,NA,NA,NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,3902,FALSE 83 | "ForC",830,"Jianfengling",NA,NA,"","NAC","Hainan","China",18.61,108.84,"890",NA,"19.8","14.8","NAC","2348.75",NA,"clay","NAC","NAC","NAC","NAC","lateritic yellow soil","NAC",NA,"351","IndoMalay","Aw","Tropical moist forest","400","Chen_2010_daco",NA,NA,NA,"Yu_2014_hcdu",NA,0,"0",NA,NA,"",FALSE,NA,NA 84 | "GROA",13973,"Jianfengling",NA,NA,NA,"NAC","Hainan Island","China",18.623056,104.68,"900",NA,"22.1","NAC","NAC","2300",NA,"","NaN","NaN","NaN","Lateritic yellow",NA,NA,NA,NA,NA,NA,NA,NA,"Li_1995_sobo",NA,NA,0,"[Cook-Patton database citation, in ForC format]","R script by Valentine Herrmann",NA,NA,NA,NA,NA,TRUE,13973,FALSE 85 | -------------------------------------------------------------------------------- /GROA-ForC_integration/scripts/ID_potential_duplicates_SITES_betweenForC_and_GROA.R: -------------------------------------------------------------------------------- 1 | ###################################################### 2 | # Purpose: Import GROA SITE data into ForC SITES AND Identidfy potential duplicates 3 | # Developped by: Valentine Herrmann - HerrmannV@si.edu 4 | # R version 3.4.4 (2018-03-15) 5 | ###################################################### 6 | 7 | # Clean environment #### 8 | rm(list = ls()) 9 | 10 | # Set working directory as ForC main folder #### 11 | setwd(".") 12 | 13 | # Load libaries #### 14 | library(RCurl) 15 | library(dplyr) 16 | # Load data #### 17 | 18 | ## GROA data #### 19 | GROA_measurements <- read.csv("data/nonsoil_litter_CWD.csv", stringsAsFactors = F) 20 | GROA_sites <- read.csv("data/sitesf.csv", stringsAsFactors = F) 21 | GROA_litterature <- read.csv("data/GROA literature.csv", stringsAsFactors = F) 22 | 23 | ## ForC data #### 24 | ForC_files <- "ForC_sites.csv" 25 | 26 | ForC_data <- NULL 27 | for(f in ForC_files) { 28 | cat("Reading", f, "...\n") 29 | name <- toupper(gsub("ForC_|\\.csv", "", f)) 30 | ForC_data[[name]] <- read.csv(text=getURL(paste0("https://raw.githubusercontent.com/forc-db/ForC/master/data/", f)), header=T, stringsAsFactors = F) 31 | 32 | ForC_data[[name]]$NEW_RECORD <- FALSE 33 | } # for(f in forC_files) 34 | 35 | ## variable_name_conversion table #### 36 | variable_name_conversion <- read.csv("GROA-ForC mapping/variable_name_conversion.csv", stringsAsFactors = F) 37 | 38 | # Settings #### 39 | ## set refor.type to plot.name key 40 | refor.type.to.plot.name.key <- data.frame(plot.name = c("regrowth stand regenerating via spontaneous natural regeneration","regrowth stand regenerating via assisted natural regeneration","regrowth stand regenerating via initial tree planting", "diverse species plantation", "monoculture plantation", "intensive tree monocrop", "multistrata stand", "stand with tree intercropping", "silvopastoral system", "transitional ecosystem", "cropland", "pasture", "intact/ old growth stand", "fire", "harvest", "shifting cultivation"), row.names = c("SNR", "ANR", "ITP", "DP", "MP", "TMC", "MS", "TI", "SP", "TR", "C", "PA", "OG", "F", "H", "SC"), stringsAsFactors = F) 41 | 42 | # pre-fixes and preparations #### 43 | 44 | ## merge non soil and soil tables 45 | # names(GROA_measurements)[!names(GROA_measurements) %in% names(GROA_measurements_soil)] 46 | # 47 | # GROA_measurements_soil$sites.sitename <- GROA_sites$site.sitename[match(GROA_measurements_soil$site.id, GROA_sites$site.id)] 48 | # GROA_measurements_soil$country <- GROA_sites$site.country[match(GROA_measurements_soil$site.id, GROA_sites$site.id)] 49 | # GROA_measurements_soil$citations.title <- GROA_litterature$study.id[match(GROA_measurements_soil$study.id, GROA_litterature$study.id)] 50 | 51 | ## create ForC.site.ID column in GROA 52 | ## this will hold the ForC of sites that are duplicates 53 | GROA_sites$ForC.site.ID <- NA 54 | 55 | 56 | ## create citation.ID 57 | GROA_litterature$citation.ID <- paste(GROA_litterature$citations.author, GROA_litterature$citations.year, substr(gsub('(? 0, soil.texture, "NAC") 104 | 105 | ## average numerical values accross plot.id 106 | sand.silt.clay <- sand.silt.clay[grepl(":", sand.silt.clay)] 107 | sand.silt.clay <- strsplit(sand.silt.clay, ":") 108 | sand <- mean(as.numeric(sapply(sand.silt.clay, "[[", 1))) 109 | silt <- mean(as.numeric(sapply(sand.silt.clay, "[[", 2))) 110 | clay <- mean(as.numeric(sapply(sand.silt.clay, "[[", 3))) 111 | } else { 112 | soil.texture <- "NAC" 113 | sand <- "NAC" 114 | silt <- "NAC" 115 | clay <- "NAC" 116 | } 117 | 118 | #### put in ForC format 119 | 120 | GROA_record_forc_format <- data.frame( 121 | site.ID = newForC.siteID, # max(ForC_data$SITES$site.ID) + 1, 122 | sites.sitename = GROA_sites$site.sitename[i], 123 | city = "NAC", 124 | state = ifelse(is.na(GROA_sites$site.state[i]), "NAC", GROA_sites$site.state[i]), 125 | country = ifelse(is.na(GROA_sites$site.country[i]), "NAC", GROA_sites$site.country[i]), 126 | lat = ifelse(is.na(GROA_sites$lat_dec[i]), "NAC", GROA_sites$lat_dec[i]), 127 | lon = ifelse(is.na(GROA_sites$long_dec[i]), "NAC", GROA_sites$long_dec[i]), 128 | masl = ifelse(is.na(GROA_sites$elevation[i]), "NAC", GROA_sites$elevation[i]), 129 | mat = ifelse(is.na(GROA_sites$AMT[i]), "NAC", as.character(GROA_sites$AMT[i])), 130 | min.temp = "NAC", 131 | max.temp = "NAC", 132 | map = ifelse(is.na(GROA_sites$AMP[i]), "NAC", as.character(GROA_sites$AMP[i])), 133 | soil.texture = soil.texture, 134 | sand = as.character(sand), 135 | silt = as.character(silt), 136 | clay = as.character(clay), 137 | soil.classification = ifelse(is.na(GROA_sites$soil.classification[i]), "NAC", GROA_sites$soil.classification[i]), 138 | measurement.refs = GROA_sites$measurement.refs[i], 139 | GROA.site.ID = GROA_sites$site.id[i], 140 | lacks.info.from.ori.pub = 0, 141 | loaded.from = "[Cook-Patton database citation, in ForC format]", 142 | loaded.by = "R script by Valentine Herrmann", 143 | NEW_RECORD = TRUE, 144 | OLD_RECORD = FALSE 145 | # tropical.extratropical = 146 | ) 147 | 148 | 149 | ## add to corresponding table depending on if it is a new site, a duplicate, or a potential duplicate #### 150 | 151 | 152 | 153 | 154 | # if sitename exists #### 155 | 156 | if(GROA_record_forc_format$sites.sitename %in% ForC_data$SITES$sites.sitename) { 157 | forC_record <- ForC_data$SITES[ForC_data$SITES$sites.sitename %in% GROA_record_forc_format$sites.sitename, ] 158 | 159 | # if same measurement.refs --> add to duplicate table with ForC.site.ID, along with ForC site + add ForC.site.ID into GROA 160 | if(ForC_data$SITES$measurement.refs[ ForC_data$SITES$sites.sitename %in% sites.sitename] %in% measurement.ref) { 161 | 162 | true.duplicate.sites <- rbind(true.duplicate.sites, 163 | bind_rows(forC_record, GROA_record_forc_format)) 164 | 165 | GROA_sites$ForC.site.ID[i] <- ForC_data$SITES$site.ID[ ForC_data$SITES$sites.sitename %in% sites.sitename] 166 | 167 | ## compare info to see if GROA has better things 168 | apply(bind_rows(forC_record, GROA_record_forc_format)[, c("country", "lat", "lon", "masl", "geography.notes", "mat", "min.temp", "max.temp", "map", "climate.notes", "soil.texture", "sand", "silt", "clay", "soil.classification", 'soil.notes', "hydrology.notes", "site.notes", "geographic.area", "biogeog", "Koeppen", "FAO.ecozone")], 2, function(x) { 169 | if((is.na(x[1]) | x[1] %in% c("NAC", "NaN", "NRA", "NI", "")) & !(is.na(x[2]) | x[2] %in% c("NAC", "NaN", "NRA", "NI", ""))) 170 | { print(x) 171 | # readline() 172 | } 173 | }) 174 | 175 | 176 | } # if same measurement.refs --> add to duplicate table with ForC.site.ID, along with ForC site 177 | 178 | # if different measurement.refs --> add to potential duplicates table, along with ForC site 179 | if(!ForC_data$SITES$measurement.refs[ ForC_data$SITES$sites.sitename %in% sites.sitename] %in% measurement.ref) { 180 | 181 | GROA_record_forc_format$site.ID <- GROA_record_forc_format$GROA.site.ID 182 | 183 | potential.duplicate.sites <- rbind(potential.duplicate.sites, 184 | bind_rows(data.frame(From = "ForC", forC_record), data.frame(From = "GROA", GROA_record_forc_format))) 185 | } # if different measurement.refs --> add to potential duplicates table, along with ForC site 186 | } # if(GROA_record_forc_format$sites.sitename %in% ForC_data$SITES$sites.sitename) 187 | 188 | # if sitename does NOT exists #### 189 | 190 | if(!GROA_record_forc_format$sites.sitename %in% ForC_data$SITES$sites.sitename) { 191 | legit.new.sites <- rbind(legit.new.sites, bind_rows(ForC_data$SITES[NULL,], GROA_record_forc_format)) 192 | } #if(!GROA_record_forc_format$sites.sitename %in% ForC_data$SITES$sites.sitename) 193 | 194 | } # for( i in 1:nrow(GROA_sites)) 195 | 196 | # save #### 197 | 198 | write.csv(true.duplicate.sites, file = "new_data/potential_duplicates/true.duplicate.sites.csv", row.names = F) 199 | write.csv(potential.duplicate.sites, file = "new_data/potential_duplicates/potential.duplicate.sites.csv", row.names = F) 200 | write.csv(potential.duplicate.sites, file = "new_data/new_SITES.csv", row.names = F) 201 | 202 | write.csv(GROA_sites, file = 'new_data/GROA_sites.csv', row.names = F) 203 | 204 | # ID potential duplicates 205 | 206 | # Load libaries #### 207 | # library(lubridate) 208 | library(fields) 209 | 210 | 211 | # Load data #### 212 | SITES <- ForC_data$SITES # read.csv("data/ForC_sites.csv", stringsAsFactors = F) 213 | # MEASUREMENTS <- read.csv("data/ForC_measurements.csv", stringsAsFactors = F) 214 | 215 | na_codes <- c("NA", "NI", "NRA", "NaN", "NAC") 216 | my_is.na <- function(x) { is.na(x) | x %in% na_codes} 217 | my_na.omit <- function(x) { return(x[!my_is.na(x)])} 218 | 219 | 220 | # Find groups of potential duplicates #### 221 | 222 | ## first look for sites with same names and same 223 | 224 | ## list of columns to compare (beside lat and lon) - fields related to physical environment #### 225 | # col.to.compare <- c("masl", "geography.notes", "mat", "min.temp", "max.temp", "map", "climate.notes", "soil.texture", "soil.classification", "soil.notes", "hydrology.notes", "site.notes") 226 | col.to.compare <- c("site.ref", "loaded.from") 227 | 228 | ## Find groups of SITES that are within a 5 km buffer #### 229 | 230 | ### Set up distance threshold 231 | threshold.in.km = 5 # 5 km 232 | 233 | ### distance matrix 234 | dist.in.km.matrix <- rdist.earth(SITES[, c("lon", "lat")], miles = F, R = 6378.137) 235 | 236 | ### get the clusterID of sites 237 | fit <- hclust(as.dist(dist.in.km.matrix), method = "single") 238 | clusters <- cutree(fit,h = threshold.in.km) 239 | 240 | table(clusters) 241 | sum(table(clusters) > 1) # 572 clusters of more than one site 242 | 243 | clusters_with_potential_duplicates <- names(table(clusters))[table(clusters) > 1] 244 | 245 | ## Within each cluster of potential duplicates, compare the fields related to physical environement. When missing, consider as potential duplicates. 246 | 247 | SITES$potential_duplicate_group <- 0 248 | SITES$potential_duplicate_group_parsed <- 0 249 | 250 | list.all.duplicate.groupings <- list() 251 | 252 | 253 | for(cluster in clusters_with_potential_duplicates) { 254 | 255 | s <- SITES[clusters %in% cluster, ] 256 | 257 | group.c <- data.frame( cluster= rep(cluster, nrow(s))) 258 | 259 | for(c in col.to.compare) { 260 | 261 | # consider as potential duplicates if... 262 | ## all are NA, 263 | ## none are NA and at least 2 different sources 264 | ## some are NA, consider as potential duplicates 265 | 266 | if (all(my_is.na(s[, c]))) group.c[, c] <- rep(1, length(s[, c])) 267 | 268 | if((!any(my_is.na(s[, c])) & length(unique(s[, c])) > 1) | (!all(my_is.na(s[, c])) & any(my_is.na(s[, c])))) { 269 | 270 | group.c[, c] <- rep(0, length(s[, c])) 271 | 272 | duplicates <- s[, c][duplicated(s[, c])] 273 | duplicates <- duplicates[!my_is.na(duplicates)] 274 | 275 | if ( length(unique(duplicates)) == 1 ) { 276 | group.c[, c][s[, c] %in% duplicates] <- seq(s[, c][s[, c] %in% duplicates]) 277 | group.c[, c][!s[, c] %in% duplicates] <- paste(seq(s[, c][s[, c] %in% duplicates]), collapse = ",") 278 | } else { 279 | group.c[, c] <- rep(1, length(s[, c])) 280 | } 281 | } 282 | 283 | # if all are not NA and are all the same, then they are not duplicates but we can still put them in a group (mostly to double check code) 284 | 285 | if((!any(my_is.na(s[, c])) & length(unique(s[, c])) == 1)) { 286 | group.c[, c] <- seq(length(s[, c])) 287 | } 288 | 289 | } 290 | 291 | list.all.duplicate.groupings[[which(clusters_with_potential_duplicates %in% cluster)]] <- group.c 292 | 293 | SITES$potential_duplicate_group[clusters %in% cluster] <- which(clusters_with_potential_duplicates %in% cluster) # create a "cluser ID" 294 | SITES$potential_duplicate_group_parsed[clusters %in% cluster] <- group.c[,1+ which.max(apply(group.c[,-1], 2, max))] # get the grouping that is the most "informed" 295 | 296 | if(length(SITES$potential_duplicate_group_parsed[clusters %in% cluster]) == length(unique(SITES$potential_duplicate_group_parsed[clusters %in% cluster]))) { 297 | SITES$potential_duplicate_group[clusters %in% cluster] <- 0 298 | SITES$potential_duplicate_group_parsed[clusters %in% cluster] <- 0 299 | } 300 | } 301 | 302 | 303 | 304 | # save #### 305 | potential_duplicate_group_including_GROA <- names(which(tapply(SITES$NEW_RECORD, SITES$potential_duplicate_group, sum) > 0)) 306 | potential_duplicate_group_including_GROA <- potential_duplicate_group_including_GROA[!potential_duplicate_group_including_GROA %in% "0"] 307 | potential_dup_SITES <- SITES[SITES$potential_duplicate_group %in% potential_duplicate_group_including_GROA, ] 308 | potential_dup_SITES <- potential_dup_SITES[order(potential_dup_SITES$potential_duplicate_group, potential_dup_SITES$sites.sitename),] 309 | View(potential_dup_SITES) 310 | 311 | 312 | write.csv(potential_dup_SITES, file = "new_data/potential_duplicates/sites.csv", row.names = F) 313 | # 314 | # old_sites <- data.frame(FROM = "GROA", filter(ForC_data$SITES, OLD_RECORD==TRUE)) 315 | # 316 | # old_SITES_from_ForC <- data.frame(FROM = "ForC", ForC_data$SITES[ForC_data$SITES$sites.sitename %in% old_sites$sites.sitename & ForC_data$SITES$OLD_RECORD %in% F,]) 317 | # 318 | # old_sites <- rbind(old_SITES_from_ForC, old_sites) 319 | # old_sites <- old_sites[order(old_sites$sites.sitename),] 320 | # old_sites 321 | 322 | 323 | # write.csv(old_sites, "new_data/old_SITES.csv", row.names = F) 324 | 325 | -------------------------------------------------------------------------------- /GROA-ForC_integration/scripts/archive/Fill_in_veg_notes_after_the_big_import.R: -------------------------------------------------------------------------------- 1 | ###################################################### 2 | # Purpose: add veg.notes = GROA_measurements$Species[i], after the fact (first big import ignored that field mistakenly) 3 | # Developped by: Valentine Herrmann - HerrmannV@si.edu 4 | # R version 3.4.4 (2018-03-15) 5 | ###################################################### 6 | 7 | # Clean environment #### 8 | rm(list = ls()) 9 | 10 | # Set working directory as ForC main folder #### 11 | setwd("C:/Users/HerrmannV/Dropbox (Smithsonian)/GitHub/forc-db/GROA") # needs to be the GROA repo (not GROA-ForC_integration sub-folder) 12 | 13 | # Load libaries #### 14 | library(RCurl) 15 | library(dplyr) 16 | 17 | # Load data #### 18 | 19 | ## GROA data #### 20 | GROA_measurements <- read.csv("data/biomass_litter_CWD.csv", stringsAsFactors = F) 21 | 22 | ## ForC data #### 23 | na_codes <- c("NA", "NI", "NRA", "NaN", "NAC") # "999" 24 | my_is.na <- function(x) { is.na(x) | x %in% na_codes} 25 | my_na.omit <- function(x) { return(x[!my_is.na(x)])} 26 | 27 | url <- "https://github.com/forc-db/ForC/tree/master/data" 28 | x <- readLines(url) 29 | goodlines = ".csv" 30 | try = grep(goodlines,x,value=TRUE) 31 | try = try[grepl('title=(.*) id=', try, perl = T)] 32 | try <- gsub('"', "", try) 33 | try.regexec <- regexec('title=(.*) id=', try, perl = T) 34 | try.regmatches <- regmatches(try, try.regexec) 35 | 36 | ForC_files <- sapply(try.regmatches, function(x) x[2]) 37 | ForC_files <- ForC_files[!ForC_files %in% "ForC_sites_missing_coordinates.csv"] 38 | 39 | ForC_data <- NULL 40 | for(f in c("ForC_measurements.csv")) { 41 | cat("Reading", f, "...\n") 42 | name <- toupper(gsub("ForC_|\\.csv", "", f)) 43 | ForC_data[[name]] <- read.csv(text=getURL(paste0("https://raw.githubusercontent.com/forc-db/ForC/master/data/", f)), header=T, stringsAsFactors = F) 44 | 45 | ForC_data[[name]]$NEW_RECORD <- FALSE 46 | 47 | if(f %in% c("ForC_history.csv", "ForC_sites.csv")) ForC_data[[name]]$GROA.site.ID <- NA 48 | if(f %in% c("ForC_measurements.csv")) ForC_data[[name]]$GROA.measurement.ID <- NA 49 | } # for(f in forC_files) 50 | 51 | 52 | ## measurement mapping #### 53 | measurementID_mapping <- read.csv("GROA-ForC_integration/GROA-ForC mapping/GROA-ForC_measurements_mapping.csv") 54 | 55 | 56 | # fill in veg.note #### 57 | 58 | for(i in 1:nrow(measurementID_mapping)) { 59 | ID_ForC <- measurementID_mapping$ForC.measurement.ID[i] 60 | ID_GROA <- measurementID_mapping$GROA.measurement.ID[i] 61 | 62 | idx_ForC <- ForC_data$MEASUREMENTS$measurement.ID %in% ID_ForC 63 | idx_GROA <- GROA_measurements$measurement.id %in% ID_GROA 64 | 65 | veg.notes_ForC <- ForC_data$MEASUREMENTS$veg.notes[idx_ForC] 66 | species_GROA <- GROA_measurements$species[idx_GROA] 67 | 68 | if(!species_GROA %in% "" & length(veg.notes_ForC)>0) { # GROA species is not empty 69 | if(veg.notes_ForC %in% "tropical wet forest") stop() 70 | new_veg.notes_ForC <- paste(ifelse(my_is.na(veg.notes_ForC) | veg.notes_ForC == "", "", veg.notes_ForC), paste0("GROA species = ", species_GROA), sep = ifelse(my_is.na(veg.notes_ForC) | veg.notes_ForC == "", "", "; ")) 71 | 72 | ForC_data$MEASUREMENTS$veg.notes[idx_ForC] <- new_veg.notes_ForC 73 | } 74 | 75 | 76 | } 77 | 78 | write.csv(select(ForC_data$MEASUREMENTS, -NEW_RECORD, -GROA.measurement.ID), paste0(dirname(getwd()), "/forc/data/ForC_measurements.csv"), row.names = F) 79 | 80 | 81 | 82 | 83 | -------------------------------------------------------------------------------- /GROA-ForC_integration/scripts/archive/Importing_GROA_into_ForC.R: -------------------------------------------------------------------------------- 1 | ###################################################### 2 | # Purpose: Import GROA data into ForC 3 | # Developped by: Valentine Herrmann - HerrmannV@si.edu 4 | # R version 3.4.4 (2018-03-15) 5 | ###################################################### 6 | 7 | # Clean environment #### 8 | rm(list = ls()) 9 | 10 | # Set working directory as ForC main folder #### 11 | setwd(".") 12 | 13 | # Load libaries #### 14 | library(RCurl) 15 | library(dplyr) 16 | # Load data #### 17 | 18 | ## GROA data #### 19 | # GROA_measurements <- read.csv("example data/GROA_measurements.csv", stringsAsFactors = F) 20 | # GROA_sites <- read.csv("example data/GROA_sites.csv", stringsAsFactors = F) 21 | # GROA_litterature <- read.csv("example data/GROA_litterature.csv", stringsAsFactors = F) 22 | 23 | GROA_measurements <- read.csv("data/nonsoil_litter_CWD.csv", stringsAsFactors = F) 24 | GROA_measurements_soil <- read.csv("data/soil.csv", stringsAsFactors = F) 25 | GROA_sites <- read.csv("data/sitesf.csv", stringsAsFactors = F) 26 | GROA_litterature <- read.csv("data/GROA literature.csv", stringsAsFactors = F) 27 | 28 | ## ForC data #### 29 | url <- "https://github.com/forc-db/ForC/tree/master/data" 30 | x <- readLines(url) 31 | goodlines = ".csv" 32 | try = grep(goodlines,x,value=TRUE) 33 | try = try[grepl('title=(.*) id=', try, perl = T)] 34 | try <- gsub('"', "", try) 35 | try.regexec <- regexec('title=(.*) id=', try, perl = T) 36 | try.regmatches <- regmatches(try, try.regexec) 37 | 38 | ForC_files <- sapply(try.regmatches, function(x) x[2]) 39 | 40 | ForC_data <- NULL 41 | for(f in ForC_files) { 42 | cat("Reading", f, "...\n") 43 | name <- toupper(gsub("ForC_|\\.csv", "", f)) 44 | ForC_data[[name]] <- read.csv(text=getURL(paste0("https://raw.githubusercontent.com/forc-db/ForC/master/data/", f)), header=T, stringsAsFactors = F) 45 | 46 | ForC_data[[name]]$NEW_RECORD <- FALSE 47 | ForC_data[[name]]$OLD_RECORD = FALSE 48 | } # for(f in forC_files) 49 | 50 | ## variable_name_conversion table #### 51 | variable_name_conversion <- read.csv("GROA-ForC mapping/variable_name_conversion.csv", stringsAsFactors = F) 52 | 53 | # Settings #### 54 | ## set refor.type to plot.name key 55 | refor.type.to.plot.name.key <- data.frame(plot.name = c("regrowth stand regenerating via spontaneous natural regeneration","regrowth stand regenerating via assisted natural regeneration","regrowth stand regenerating via initial tree planting", "diverse species plantation", "monoculture plantation", "intensive tree monocrop", "multistrata stand", "stand with tree intercropping", "silvopastoral system", "transitional ecosystem", "cropland", "pasture", "intact/ old growth stand", "fire", "harvest", "shifting cultivation"), row.names = c("SNR", "ANR", "ITP", "DP", "MP", "TMC", "MS", "TI", "SP", "TR", "C", "PA", "OG", "F", "H", "SC"), stringsAsFactors = F) 56 | 57 | # pre-fixes and preparations #### 58 | 59 | ## merge non soil and soil tables 60 | names(GROA_measurements)[!names(GROA_measurements) %in% names(GROA_measurements_soil)] 61 | 62 | GROA_measurements_soil$sites.sitename <- GROA_sites$site.sitename[match(GROA_measurements_soil$site.id, GROA_sites$site.id)] 63 | GROA_measurements_soil$country <- GROA_sites$site.country[match(GROA_measurements_soil$site.id, GROA_sites$site.id)] 64 | GROA_measurements_soil$citations.title <- GROA_litterature$study.id[match(GROA_measurements_soil$study.id, GROA_litterature$study.id)] 65 | 66 | 67 | 68 | ## create citation.ID 69 | GROA_litterature$citation.ID <- paste(GROA_litterature$citations.author, GROA_litterature$citations.year, substr(gsub('(? 0, soil.texture, "NAC") 110 | 111 | ## average numerical values accross plot.id 112 | sand.silt.clay <- sand.silt.clay[grepl(":", sand.silt.clay)] 113 | sand.silt.clay <- strsplit(sand.silt.clay, ":") 114 | sand <- mean(as.numeric(sapply(sand.silt.clay, "[[", 1))) 115 | silt <- mean(as.numeric(sapply(sand.silt.clay, "[[", 2))) 116 | clay <- mean(as.numeric(sapply(sand.silt.clay, "[[", 3))) 117 | } else { 118 | soil.texture <- "NAC" 119 | sand <- "NAC" 120 | silt <- "NAC" 121 | clay <- "NAC" 122 | } 123 | 124 | # deal with the easier stuff here 125 | ForC_data$SITES <- bind_rows( 126 | ForC_data$SITES , 127 | data.frame( 128 | site.ID = max(ForC_data$SITES$site.ID) + 1, 129 | sites.sitename = sites.sitename, 130 | city = "NAC", 131 | state = ifelse(is.na(GROA_sites$site.state[i]), "NAC", GROA_sites$site.state[i]), 132 | country = ifelse(is.na(GROA_sites$site.country[i]), "NAC", GROA_sites$site.country[i]), 133 | lat = ifelse(is.na(GROA_sites$lat_dec[i]), "NAC", GROA_sites$lat_dec[i]), 134 | lon = ifelse(is.na(GROA_sites$long_dec[i]), "NAC", GROA_sites$long_dec[i]), 135 | masl = ifelse(is.na(GROA_sites$elevation[i]), "NAC", GROA_sites$elevation[i]), 136 | mat = ifelse(is.na(GROA_sites$AMT[i]), "NAC", as.character(GROA_sites$AMT[i])), 137 | min.temp = "NAC", 138 | max.temp = "NAC", 139 | map = ifelse(is.na(GROA_sites$AMP[i]), "NAC", as.character(GROA_sites$AMP[i])), 140 | soil.texture = soil.texture, 141 | sand = as.character(sand), 142 | silt = as.character(silt), 143 | clay = as.character(clay), 144 | soil.classification = ifelse(is.na(GROA_sites$soil.classification[i]), "NAC", GROA_sites$soil.classification[i]), 145 | measurement.ref = GROA_sites$measurement.ref[i], 146 | ref.notes = paste("GROA site.ID =", GROA_sites$site.id[i]), 147 | lacks.info.from.ori.pub = 0, 148 | loaded.from = "[Cook-Patton database citation, in ForC format]", 149 | loaded.by = "R script by Valentine Herrmann", 150 | NEW_RECORD = FALSE, 151 | OLD_RECORD = TRUE 152 | # tropical.extratropical = 153 | ) 154 | ) 155 | 156 | } else { 157 | cat("Creating new site:", sites.sitename, "\n") 158 | 159 | # deal wit soil texture separately here 160 | sand.silt.clay <- GROA_measurements[GROA_measurements$sites.sitename %in% sites.sitename, "sand.silt.clay"] 161 | 162 | if(!all(is.na(sand.silt.clay))) { 163 | ## get character sctring describing soil texture and keeping longest if there is more than one value 164 | soil.texture <- sand.silt.clay[!grepl(":", sand.silt.clay)] 165 | soil.texture <- soil.texture[which.max(nchar(soil.texture))] 166 | soil.texture <- ifelse(length(soil.texture) > 0, soil.texture, "NAC") 167 | 168 | ## average numerical values accross plot.id 169 | sand.silt.clay <- sand.silt.clay[grepl(":", sand.silt.clay)] 170 | sand.silt.clay <- strsplit(sand.silt.clay, ":") 171 | sand <- mean(as.numeric(sapply(sand.silt.clay, "[[", 1))) 172 | silt <- mean(as.numeric(sapply(sand.silt.clay, "[[", 2))) 173 | clay <- mean(as.numeric(sapply(sand.silt.clay, "[[", 3))) 174 | } else { 175 | soil.texture <- "NAC" 176 | sand <- "NAC" 177 | silt <- "NAC" 178 | clay <- "NAC" 179 | } 180 | 181 | # deal with the easier stuff here 182 | ForC_data$SITES <- bind_rows( 183 | ForC_data$SITES , 184 | data.frame( 185 | site.ID = max(ForC_data$SITES$site.ID) + 1, 186 | sites.sitename = sites.sitename, 187 | city = "NAC", 188 | state = ifelse(is.na(GROA_sites$site.state[i]), "NAC", GROA_sites$site.state[i]), 189 | country = ifelse(is.na(GROA_sites$site.country[i]), "NAC", GROA_sites$site.country[i]), 190 | lat = ifelse(is.na(GROA_sites$lat_dec[i]), "NAC", GROA_sites$lat_dec[i]), 191 | lon = ifelse(is.na(GROA_sites$long_dec[i]), "NAC", GROA_sites$long_dec[i]), 192 | masl = ifelse(is.na(GROA_sites$elevation[i]), "NAC", GROA_sites$elevation[i]), 193 | mat = ifelse(is.na(GROA_sites$AMT[i]), "NAC", as.character(GROA_sites$AMT[i])), 194 | min.temp = "NAC", 195 | max.temp = "NAC", 196 | map = ifelse(is.na(GROA_sites$AMP[i]), "NAC", as.character(GROA_sites$AMP[i])), 197 | soil.texture = soil.texture, 198 | sand = as.character(sand), 199 | silt = as.character(silt), 200 | clay = as.character(clay), 201 | soil.classification = ifelse(is.na(GROA_sites$soil.classification[i]), "NAC", GROA_sites$soil.classification[i]), 202 | ref.notes = paste("GROA site.ID =", GROA_sites$site.id[i]), 203 | lacks.info.from.ori.pub = 0, 204 | loaded.from = "[Cook-Patton database citation, in ForC format]", 205 | loaded.by = "R script by Valentine Herrmann", 206 | NEW_RECORD = TRUE, 207 | OLD_RECORD = FALSE 208 | # tropical.extratropical = 209 | ) 210 | ) 211 | } 212 | } 213 | 214 | 215 | # Create a new record in CITATIONS if one does not already exist #### 216 | 217 | ## from GROA_litterature 218 | for(i in 1:nrow(GROA_litterature)) { 219 | 220 | cat("--------------------", i, "/", nrow(GROA_litterature), "\n") 221 | cat("Record:", paste(GROA_litterature[i, 1:4], collapse = " "), "\n") 222 | 223 | citation.ID_GROA <- GROA_litterature$citation.ID[i] 224 | 225 | if(citation.ID_GROA %in% ForC_data$CITATIONS$citation.ID) { 226 | cat("Found citation", citation.ID_GROA, "in CITATIONS table\n") 227 | } else { 228 | cat("Creating new citation:", citation.ID_GROA, "\n") 229 | 230 | ForC_data$CITATIONS <- bind_rows( 231 | ForC_data$CITATIONS, 232 | data.frame( 233 | citation.ID = citation.ID_GROA, 234 | citation.doi = "NAC", 235 | citation.author = GROA_litterature$citations.author[i], 236 | citation.year = GROA_litterature$citations.year[i], 237 | citation.title = GROA_litterature$citations.title[i], 238 | NEW_RECORD = TRUE 239 | ) 240 | ) 241 | } 242 | } 243 | 244 | ## from GROA_measurements --> non need to do it because all(GROA_measurements$citations.title %in% GROA_litterature$citations.title) is TRUE. 245 | 246 | # Create a new record in MEASUREMENTS if one does not already exist #### 247 | for( i in 1:nrow(GROA_measurements)) { 248 | 249 | cat("--------------------", i, "/", nrow(GROA_measurements), "\n") 250 | cat("Record:", paste(GROA_measurements[i, 1:4], collapse = " "), "\n") 251 | 252 | sites.sitename <- GROA_measurements$sites.sitename[i] 253 | GROA_variables.name <- GROA_measurements$variables.name[i] 254 | 255 | variable.name <- variable_name_conversion[variable_name_conversion$GROA_variables.name %in% GROA_variables.name, ]$ForC_variable.name 256 | 257 | if(paste(sites.sitename, variable.name) %in% paste(ForC_data$MEASUREMENTS$sites.sitename, ForC_data$MEASUREMENTS$variable.name)) { 258 | cat("Found record", paste(sites.sitename, variable.name), "in MEASUREMENTS table\n") 259 | } else { 260 | cat("Creating new record:",paste(sites.sitename, variable.name), "\n") 261 | include_record = TRUE 262 | 263 | # deal with covariates separately here #### 264 | if(any(GROA_measurements[, c("covar_1","covar_2", "covar_3")][i,] %in% c("min_dbh"))) { 265 | idx.min_dbh <- which(GROA_measurements[, c("covar_1","covar_2", "covar_3")][i,] %in% "min_dbh") 266 | min.dbh = GROA_measurements[, c("coV1_value","coV2_value", "coV3_value")][i,][idx.min_dbh] 267 | 268 | } else { 269 | min.dbh = "NAC" 270 | } 271 | 272 | if(any(GROA_measurements[, c("covar_1","covar_2", "covar_3")][i,] %in% c("max_depth"))) { 273 | idx.max_depth <- which(GROA_measurements[, c("covar_1","covar_2", "covar_3")][i,] %in% "max_depth") 274 | depth = GROA_measurements[, c("coV1_value","coV2_value", "coV3_value")][i,][idx.max_depth] 275 | } else { 276 | depth = "NAC" 277 | } 278 | 279 | other.covariates.idx <- !GROA_measurements[, c("covar_1","covar_2", "covar_3")][i,] %in% c("min_dbh", "max_depth", "component", "components") # also ignore component and components as they will be transfered to variable name an mean. 280 | other.covariates <- unlist(GROA_measurements[, c("covar_1","covar_2", "covar_3")][i,][other.covariates.idx], use.names = F) 281 | other.cov.values <- unlist(GROA_measurements[, c("coV1_value","coV2_value", "coV3_value")][i,][other.covariates.idx], use.names = F) 282 | 283 | component.idx <- GROA_measurements[, c("covar_1","covar_2", "covar_3")][i,] %in% c("component", "components") 284 | GROA_component <- unlist(GROA_measurements[, c("coV1_value","coV2_value", "coV3_value")][i,][component.idx], use.names = F) 285 | 286 | if(!is.null(GROA_component)) { 287 | 288 | if(variable.name %in% c("total.ecosystem_2_C") & !GROA_component %in% c("forest floor + CWD", "litter + dead woody debris")) include_record = FALSE 289 | 290 | if(variable.name %in% c("organic.layer_OM")) { 291 | if(GROA_component %in% c("litter", "forest floor")) include_record = TRUE 292 | if(GROA_component %in% c("CWD", "FWD + CWD", "FWD+CWD")) { include_record = TRUE ; variable.name = "deadwood_down_OM" } 293 | if(GROA_component %in% c("forest floor + CWD", "litter + dead woody debris")) include_record = FALSE 294 | } 295 | 296 | if(variable.name %in% c("organic.layer_C")) { 297 | if(GROA_component %in% c("litter", "forest floor")) include_record = TRUE 298 | if(GROA_component %in% c("CWD", "FWD + CWD", "FWD+CWD")) { include_record = TRUE ; variable.name = "deadwood_down_C" } 299 | if(GROA_component %in% c("forest floor + CWD", "litter + dead woody debris")) include_record = FALSE 300 | } 301 | 302 | } # if(!is.na(GROA_component)) 303 | 304 | # append to measurements table now #### 305 | if(include_record) ForC_data$MEASUREMENTS <- bind_rows( ##### 306 | ForC_data$MEASUREMENTS, 307 | data.frame( ##### 308 | measurement.ID = c(max(ForC_data$MEASUREMENTS$measurement.ID)+1, max(ForC_data$MEASUREMENTS$measurement.ID) + 2)[c(TRUE, !is.na(GROA_measurements$density[i]))], 309 | sites.sitename, 310 | plot.name = GROA_measurements$plot.name[i], 311 | stand.age = as.character(GROA_measurements$stand.age[i]), 312 | dominant.life.form = ifelse(GROA_measurements$refor.type[i] %in% "PA", "2GW", 313 | ifelse(GROA_measurements$refor.type[i] %in% "C", "NAC", "woody")), 314 | dominant.veg = "NAC", 315 | veg.notes = GROA_measurements$Species[i], 316 | variable.name = c(variable.name, "stand.density")[c(TRUE, !is.na(GROA_measurements$density[i]))], 317 | date = as.character(ifelse(is.na(GROA_measurements$date[i]), "NI", GROA_measurements$date[i])), 318 | date.loc = ifelse(is.na(GROA_measurements$date[i]), 9, 8), 319 | start.date.loc = 9, 320 | end.date.loc = 9, 321 | mean = c(GROA_measurements$mean_ha[i], GROA_measurements$density[i])[c(TRUE, !is.na(GROA_measurements$density[i]))], 322 | n = as.character(ifelse(is.na(GROA_measurements$n[i]), "NI", GROA_measurements$n[i])), 323 | area.sampled = as.character(ifelse(is.na(GROA_measurements$n[i] * GROA_measurements$plot.size[i]), "NI", GROA_measurements$n[i] * GROA_measurements$plot.size[i])), 324 | notes = paste0(ifelse(is.na(GROA_measurements$allometry[i]), "", paste0("Biomass allometries: ", GROA_measurements$allometry[i], ".")), 325 | ifelse(is.na(GROA_measurements$sub_n[i]), "", paste0(" ", GROA_measurements$sub_n[i], " sample(s) per plot.")), 326 | ifelse(is.null(GROA_component), "", paste0(" GROA component: ", GROA_component, "."))), 327 | 328 | allometry_1 = "NAC", 329 | allometry_2 = NA, 330 | 331 | min.dbh, 332 | depth, 333 | 334 | covariate_1 = other.covariates[1], 335 | coV_1.value = as.character(other.cov.values[1]), 336 | covariate_2 = other.covariates[2], 337 | coV_2.value = as.character(other.cov.values[2]), 338 | 339 | citation.ID = GROA_litterature$citation.ID[GROA_litterature$study.id %in% GROA_measurements$study.id[i]], 340 | source.notes = paste0("GROA measurement.ID #", GROA_measurements$measurement.id[i]), 341 | loaded.from = "[Cook-Patton database citation, in ForC format]", 342 | loaded.by = paste("R script by Valentine Herrmann"), 343 | checked.ori.pub = ifelse(grepl("Guo|Krankina", GROA_litterature$citation.ID[GROA_litterature$study.id %in% GROA_measurements$study.id[i]]), 0, 1), # "1" for all studies, except "0" for Guo and Krankina 344 | ForC.investigator = "Dr. Susan Cook-Patton", 345 | required.citations = "[Cook-Patton database citation, in ForC format]", 346 | flag.suspicious = 0, 347 | NEW_RECORD = TRUE 348 | ) 349 | ) 350 | } 351 | } 352 | 353 | 354 | # Create a new record in HISTORY if one does not already exist #### 355 | site_plots <- unique(paste(ForC_data$MEASUREMENTS[ForC_data$MEASUREMENTS$NEW_RECORD == 1,]$sites.sitename, ForC_data$MEASUREMENTS[ForC_data$MEASUREMENTS$NEW_RECORD == 1,]$plot.name)) 356 | 357 | s_p.with.age.date.discrepancy <- NULL 358 | s_p.with.chronosequence.to.fix <- NULL 359 | s_p.with.other.date.age.issues.to.fix <- NULL 360 | 361 | for(s_p in site_plots) { 362 | cat(paste("creating HISTORY for", s_p, "\n")) 363 | 364 | groa_sub <- GROA_measurements[paste(GROA_measurements$sites.sitename, GROA_measurements$plot.name) %in% s_p, ] 365 | sites.sitename <- unique(groa_sub$sites.sitename) 366 | plot.name <- unique(groa_sub$plot.name) 367 | plot.area <- ifelse(is.na(unique(groa_sub$n * groa_sub$plot.size)), "NAC", unique(groa_sub$n * groa_sub$plot.size)) 368 | refor.type <- unique(groa_sub$refor.type) 369 | 370 | if(s_p %in% paste(forc_data$HISTORY$sites.sitename, forc_data$HISTORY$plot.name)) { 371 | cat("Found site", sites.sitename, "\n") 372 | } else { 373 | 374 | if(length(refor.type) > 1) stop("there is more than 1 refor.type for this site") 375 | 376 | if(length(refor.type) == 1) { 377 | 378 | 379 | date <- unique(groa_sub$date) 380 | stand.age <- unique(groa_sub$stand.age) 381 | 382 | ## date age discrepancy 383 | if(length(date) > 1 & any(!is.na(stand.age) & length(stand.age) == 1)) { # Here lets assume that the age applies to the first year of measurements 384 | s_p.with.age.date.discrepancy <- c(s_p.with.age.date.discrepancy, s_p) 385 | Study_midyear <- Study_midyear[1] 386 | } 387 | 388 | ## chronosequence issue 389 | if(length(date) == 1 & (length(stand.age) > 1) ) { 390 | s_p.with.chronosequence.to.fix <- c(s_p.with.chronosequence.to.fix, s_p) 391 | warning("chronosequence issue") 392 | stand.age <- stand.age[1] 393 | } 394 | 395 | 396 | ## other issues 397 | if((length(date) > 1 & any(is.na(date))) | (length(stand.age) > 1 & any(is.na(stand.age)))) { 398 | s_p.with.other.date.age.issues.to.fix <- c(s_p.with.other.date.age.issues.to.fix, s_p) 399 | warning("chronosequence issue") 400 | date <- date[!is.na(date)][1] 401 | stand.age <- stand.age[!is.na(stand.age)][1] 402 | } 403 | 404 | 405 | 406 | 407 | if(refor.type %in% "SNR") { 408 | 409 | event.sequence <- 1:3 410 | hist.cat <- c("Disturbance", "Establishment", "Regrowth") 411 | hist.type <- c(ifelse(refor.type %in% "C", 'Cultivation', 412 | ifelse(refor.type %in% "SC", "Shifting cultivation", 413 | ifelse(refor.type %in% "H", "Harvest", 414 | ifelse(refor.type %in% "F", "Burned", 415 | ifelse(refor.type %in% "D", "NAC", 416 | ifelse(refor.type %in% "PA", "Grazed", 417 | ifelse(refor.type %in% "OG", "No severe disturbance", NA)))))))) 418 | } # if(refor.type %in% "SNR" 419 | 420 | if(refor.type %in% "OG") { 421 | 422 | } # if(refor.type %in% "OG") 423 | 424 | hist.cat = c("Establishement", "Regrowth", manip_conversion[, c("Hist.cat", "Hist.cat2", "Hist.cat3")]) 425 | hist.type = c("Establishment of oldest trees", "Initiation of post-disturbance cohort (planted or natural)", manip_conversion[, c("Hist.type", "Hist.type2", "Hist.type3")]) 426 | 427 | event.sequence = seq(hist.cat) 428 | 429 | date = unique(ifelse(!is.na(Study_midyear - Age_disturbance), floor(Study_midyear - Age_disturbance), 430 | ifelse(!is.na(Study_midyear - Age_ecosystem), floor((Study_midyear - Age_ecosystem)), "NAC"))) 431 | 432 | date = c(rep(date, 2), rep("NAC", length(hist.cat) - 2)) 433 | 434 | date.loc = "NAC" 435 | 436 | est.regrowth.assumed.same.year = c(1, 1, rep(NA, length(hist.cat) - 2)) 437 | 438 | level = c(NA, NA, rep("NAC", length(hist.cat) - 2)) 439 | units = NA 440 | 441 | percent.mortality = c(NA, NA, manip_conversion[, c("percent.mortality", "percent.mortality2", "percent.mortality3")]) 442 | hist.notes = c(NA, NA, rep(unique(paste(groa_sub$Manipulation, groa_sub$Manipulation_level)), length(hist.cat) -2)) 443 | 444 | 445 | rows.to.add <- data.frame( ##### 446 | history.ID = ceiling(max(forc_data$HISTORY$history.ID)) + seq(event.sequence) / 100, 447 | sites.sitename, 448 | plot.name, 449 | plot.area, 450 | event.sequence = as.character(event.sequence), 451 | date, 452 | date.loc, 453 | hist.cat = unlist(hist.cat), 454 | hist.type = unlist(hist.type), 455 | est.regrowth.assumed.same.year, 456 | level, 457 | units, 458 | percent.mortality = unlist(percent.mortality), 459 | hist.notes, 460 | NEW_RECORD = TRUE, 461 | stringsAsFactors = F 462 | ) 463 | 464 | rows.to.add <- rows.to.add[!is.na(rows.to.add$hist.cat),] 465 | 466 | 467 | forc_data$HISTORY <- bind_rows(forc_data$HISTORY, rows.to.add) 468 | } # if(length(manip) == 1) 469 | } # if(sites.sitename %in% forc_data$HISTORY$sites.sitename) 470 | 471 | } # for(s_p in site_plots) { 472 | 473 | 474 | 475 | 476 | 477 | 478 | cat("All done.\n") 479 | 480 | 481 | 482 | 483 | # save #### 484 | 485 | sum(ForC_data$CITATIONS$NEW_RECORD) 486 | sum(ForC_data$MEASUREMENTS$NEW_RECORD) 487 | sum(ForC_data$SITES$NEW_RECORD) 488 | sum(ForC_data$SITES$OLD_RECORD) 489 | 490 | write.csv(filter(ForC_data$SITES, NEW_RECORD==TRUE), "new_data/new_SITES.csv", row.names = F) 491 | write.csv(filter(ForC_data$CITATIONS, NEW_RECORD==TRUE), "new_data/new_CITATIONS.csv", row.names = F) 492 | write.csv(filter(ForC_data$MEASUREMENTS, NEW_RECORD==TRUE), "new_data/new_MEASUREMENTS.csv", row.names = F) 493 | 494 | old_sites <- data.frame(FROM = "GROA", filter(ForC_data$SITES, OLD_RECORD==TRUE)) 495 | 496 | old_SITES_from_ForC <- data.frame(FROM = "ForC", ForC_data$SITES[ForC_data$SITES$sites.sitename %in% old_sites$sites.sitename & ForC_data$SITES$OLD_RECORD %in% F,]) 497 | 498 | old_sites <- rbind(old_SITES_from_ForC, old_sites) 499 | old_sites <- old_sites[order(old_sites$sites.sitename),] 500 | old_sites 501 | write.csv(old_sites, "new_data/old_SITES.csv", row.names = F) 502 | 503 | -------------------------------------------------------------------------------- /MappingGlobalCarbon/README.md: -------------------------------------------------------------------------------- 1 | ### Machine Learning Module and Code for *Mapping carbon accumulation potential from global natural forest regrowth* 2 | -------------------------------------------------------------------------------- /MappingGlobalCarbon/gfw_forestlearn/__init__.py: -------------------------------------------------------------------------------- 1 | #File to load modules -------------------------------------------------------------------------------- /MappingGlobalCarbon/gfw_forestlearn/convert_hdf_to_raster.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | import getopt 3 | import sys 4 | import pandas as pd 5 | import numpy as np 6 | import os 7 | import subprocess 8 | from osgeo import gdal 9 | import geopandas as gpd 10 | from shapely.geometry import Point 11 | import rasterio 12 | import multiprocessing as mp 13 | 14 | 15 | ''' 16 | Converts a large HDF or CSV file of pixel values to raster 17 | 18 | Arguments: 19 | in_csv (String): 20 | column (String): 21 | ref_file (String): 22 | out_file (String): 23 | x (String): 24 | y (String) 25 | ''' 26 | in_csv = '' 27 | column = '' 28 | ref_file = '' 29 | out_file = '' 30 | x = '' 31 | y = '' 32 | chunksize = 1000000 33 | min_0 = False 34 | 35 | print 'ARGV :', sys.argv[1:] 36 | 37 | options, remainder = getopt.getopt(sys.argv[1:], '', ['in_csv=', 38 | 'column=', 39 | 'ref_file=', 40 | 'out_file=', 41 | 'x_name=', 42 | 'y_name=', 43 | 'chunksize=', 44 | 'min_0' 45 | ]) 46 | for opt, arg in options: 47 | if opt in ('--in_csv'): 48 | in_csv = arg 49 | elif opt in ('--column'): 50 | column = arg 51 | elif opt in ('--ref_file'): 52 | ref_file = arg 53 | elif opt in ('--out_file'): 54 | out_file = arg 55 | elif opt in ('--x_name'): 56 | x = arg 57 | elif opt in ('--y_name'): 58 | y = arg 59 | elif opt in ('--chunksize'): 60 | chunksize = arg 61 | elif opt in ('--min_0'): 62 | min_0 = True 63 | 64 | xy = [x,y] 65 | 66 | 67 | src = rasterio.open(ref_file) 68 | 69 | data = np.zeros((src.height,src.width)) 70 | data[:,:] = np.nan 71 | result = np.ctypeslib.as_ctypes(data) 72 | shared_array = mp.sharedctypes.RawArray(result._type_, result) 73 | 74 | 75 | def fill_per_window(df): 76 | for i,row in df.iterrows(): 77 | #print(row) 78 | tmp = np.ctypeslib.as_array(shared_array) 79 | index = src.index(row[xy[0]],row[xy[1]]) 80 | if min_0: 81 | est = np.maximum(row[name],0) 82 | else: 83 | est = row[name] 84 | 85 | tmp[index] = est 86 | 87 | print('Entering pool') 88 | p = mp.Pool() 89 | 90 | if '.csv' in in_csv: 91 | p.imap_unordered(fill_per_window, pd.read_csv(in_csv, chunksize=chunksize) 92 | else: 93 | p.imap_unordered(fill_per_window, pd.read_hdf(in_csv, chunksize=chunksize) 94 | 95 | p.close() 96 | p.join() 97 | result = np.ctypeslib.as_array(shared_array) 98 | 99 | profile = src.profile 100 | 101 | profile.update(dtype=rasterio.float32,count=1,compress='lzw') 102 | 103 | with rasterio.open(out_file, 'w', **profile) as dst: 104 | dst.write(result.astype(rasterio.float32), 1) 105 | dst.nodata = np.nan 106 | 107 | 108 | 109 | 110 | -------------------------------------------------------------------------------- /MappingGlobalCarbon/gfw_forestlearn/fl_regression.py: -------------------------------------------------------------------------------- 1 | import subprocess 2 | import gdal 3 | import pandas as pd 4 | import numpy as np 5 | import glob 6 | import rasterio 7 | import os 8 | import datetime 9 | import csv 10 | import random 11 | from math import sqrt 12 | import pickle 13 | import math 14 | import datetime 15 | import warnings 16 | from shutil import copyfile 17 | import csv 18 | import sys 19 | import math 20 | import shutil 21 | 22 | from sklearn.model_selection import cross_val_score 23 | from sklearn import metrics 24 | from sklearn import svm 25 | from sklearn.model_selection import GridSearchCV, StratifiedKFold, validation_curve, train_test_split 26 | from sklearn.pipeline import Pipeline 27 | from sklearn.preprocessing import StandardScaler, OneHotEncoder, LabelEncoder 28 | from sklearn.compose import ColumnTransformer 29 | from sklearn.ensemble import RandomForestRegressor 30 | from sklearn.base import BaseEstimator, TransformerMixin 31 | from sklearn.decomposition import PCA 32 | from sklearn.feature_selection import SelectFromModel 33 | from sklearn.svm import LinearSVR 34 | from sklearn.neural_network import MLPClassifier 35 | from sklearn.utils import resample 36 | from sklearn.metrics import mean_squared_error 37 | import xgboost as xgb 38 | 39 | 40 | 41 | 42 | class ForestLearn(object): 43 | """ 44 | Build machine learning object that can find the best parameters for final run. 45 | 46 | """ 47 | 48 | def __init__(self, predictors=[], y_column=None, xy = [], cat_feats = [], one_hot_feats = []): 49 | """ 50 | Defines predictors, response variable, coordinate column names, binary features, categorical features, and numeric features 51 | 52 | Inputs: 53 | predictors (list): List of predictor variables to be used in model, these will also be referred to as features 54 | y_column (string): Name of response variable column in dataframes 55 | xy (list): Name of coordinate columns for x, y (or longitude, latitude) positions of pixels 56 | cat_feats (list): List of binary features that will stay (0,1) 57 | one_hot_feats (list): List of categorical features with more than one category, these will be transformed using one hot encoding to binary features. 58 | 59 | Numeric features are those that are listed in predictors but not in cat_feats or one_hot_feats. 60 | 61 | Predictors, cat_feats, and one_hot_feats are combined to ensure all features are used and removes duplicates, so you can list both cat_feats and 62 | one_hot_feats in predictors or enter them seperately. 63 | 64 | For example: 65 | predictors= ['rainfall','temperature','biome','protected'] 66 | cat_feats = ['protected'] 67 | one_hot_feats = ['biome'] 68 | 69 | OR 70 | predictors= ['rainfall','temperature'] 71 | cat_feats = ['protected'] 72 | one_hot_feats = ['biome'] 73 | 74 | are both accepted. 75 | """ 76 | # Exit if y_column is not present 77 | if y_column is None: 78 | sys.exit('"y_column" must be defined in training process...') 79 | 80 | # Merge inputted feature lists and remove duplicates 81 | predictors = list(set(predictors + cat_feats + one_hot_feats)) 82 | # Select numeric features as predictors that are not in cat_feats or one_hot_feats 83 | numeric_features = [x for x in predictors if x not in cat_feats+one_hot_feats] 84 | 85 | # Save parameters to ForestLearn object 86 | self.y_column = y_column 87 | self.xy = xy 88 | self.predictors = predictors 89 | self.numeric_features = numeric_features 90 | self.categorical_features = cat_feats 91 | self.one_hot_features = one_hot_feats 92 | self.best_params = {} 93 | self.rmse = {} 94 | self.r2 = {} 95 | self.avg_res = {} 96 | self.avg_abs_res = {} 97 | 98 | def tune_param_set(self, train, params, out_modelfilename, cv_results_filename, k=5, scoring='neg_root_mean_squared_error', n_jobs=4,verbose=1,refit=True): 99 | """ 100 | Given a dictionary of lists of parameters to try, runs GridSearchCV to use cross validation to find the best set of parameters based on the cross 101 | validation score defined in the scoring variable. 102 | Saves the best fitting model to ForestLearn object, outputs model to pickle file, and outputs cross-validation results 103 | See documentation on GridSearchCV: https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.GridSearchCV.html 104 | 105 | Inputs: 106 | train (DataFrame): Dataframe of training data containing predictors and y_column 107 | params (dictionary): Dictionary with parameters names (str) as keys and lists of parameter settings to try as values, 108 | or a list of such dictionaries, in which case the grids spanned by each dictionary in the list are explored. 109 | This enables searching over any sequence of parameter settings. 110 | out_modelfilename (string): Output file name to save trained model, using pickle, should have extension .pkl 111 | cv_results_filename (string): Output file name to save cross-validation results, should be a csv with extension .csv 112 | k (integer): Integer number for number of folds in cross-validation 113 | scoring (string): Scoring name to evaluate model, see https://scikit-learn.org/stable/modules/model_evaluation.html for options 114 | n_jobs (integer): Integer number of threads (CPUs) to train model, -1 uses all 115 | verbose (integer): Controls the verbosity: the higher, the more messages. 116 | refit (boolean): Refit an estimator using the best found parameters on the whole dataset. 117 | 118 | Returns: None 119 | """ 120 | # Define grid_search 121 | grid_search = GridSearchCV(self.mdl, params, n_jobs=n_jobs, verbose=verbose, cv=k, scoring=scoring, 122 | refit=refit, return_train_score=True) 123 | # Fit grid_search 124 | grid_search.fit(train[self.predictors], train[self.y_column]) 125 | # Save best parameters 126 | self.best_params = grid_search.best_params_ 127 | # Save best mdoel 128 | self.mdl = grid_search.best_estimator_ 129 | # Save best model to out_modelfilename 130 | pickle.dump(self.mdl, open(out_modelfilename, 'wb')) 131 | # Save cv_results to cv_results_filename 132 | cv_results_df = pd.DataFrame.from_dict(grid_search.cv_results_) 133 | cv_results_df.to_csv(cv_results_filename,index=False) 134 | return self.mdl 135 | 136 | 137 | def fit_model_with_params(self, train, out_modelfilename, in_params=None, in_modelfilename=None): 138 | """ 139 | Given a dictionary of parameters or input model filename to load parameters from trained model, trains a model with inputted parameters 140 | on training data and saves model. This parameters should only be for the machine learning part of the pipeline, named "learn". 141 | This step should only be run after setting up model pipeline type, i.e. running setup_xgb_model or setup_rf_model where the 142 | feature scaling and selecting is done. 143 | 144 | Inputs: 145 | train (DataFrame): Dataframe of training data containing predictors and y_column 146 | out_modelfilename (string): Output file name to save trained model, using pickle, should have extension .pkl 147 | in_params (dictionary): Dictionary with parameters names (str) as keys and parameter setting as value to train the model 148 | in_modelfilename (string): Input file name of trained model to load parameters, should have extension .pkl 149 | 150 | Returns: None 151 | """ 152 | # Exit if in_params or in_modelfilename is not given 153 | if (in_params is None) and (in_modelfilename is None): 154 | sys.exit('Either in_params or in_modelfilename must be provided') 155 | # If in_params is given, load parameters for "learn" machine learning part of the pipeline 156 | elif in_params: 157 | self.mdl.named_steps['learn'].set_params(**in_params) 158 | params = in_params 159 | # If in_modelfilename is given, load parameters from modelfile for "learn" machine learning part of the pipeline 160 | elif in_modelfilename: 161 | in_model = pickle.load(open(in_modelfilename, 'rb')) 162 | params = in_model.named_steps['learn'].get_params() 163 | self.mdl.named_steps['learn'].set_params(**params) 164 | # Fit model on training data in train 165 | self.mdl.fit(train[self.predictors], train[self.y_column]) 166 | # Save best parameters 167 | self.best_params = params 168 | # Save to out_modelfilename 169 | pickle.dump(self.mdl, open(out_modelfilename, 'wb')) 170 | return self.mdl 171 | 172 | def load_model_from_file(self, in_modelfilename): 173 | """ 174 | Loads inputted model and saves to ForestLearn object 175 | 176 | Inputs: 177 | in_modelfilename (string): Input file name of trained model to save, should have extension .pkl 178 | 179 | Returns: None 180 | """ 181 | self.mdl = pickle.load(open(in_modelfilename, 'rb')) 182 | self.best_params = self.mdl.named_steps['learn'].get_params() 183 | return self.mdl 184 | 185 | def save_feature_importances(self, feature_importance_filename): 186 | # """ 187 | # Saves feature importances from trained model 188 | # 189 | # Inputs: 190 | # feature_importance_filename (string): File name to save feature importances to, should have extension .csv 191 | # """ 192 | # # If one_hot_features are listed, grab the new one hot encoded feature names 193 | # # Then the list of parameters is numeric features, one hot encoded features, and categorical features 194 | # 195 | # preprocess_step = list(self.mdl.named_steps.keys())[-2] 196 | # transformer = self.mdl.named_steps[preprocess_step] 197 | # print(transformer) 198 | # if isinstance(transformer,ColumnTransformer): 199 | # print(transformer.transformers_) 200 | # elif isinstance(transformer,SelectFromModel): 201 | # print(transformer.get_support()) 202 | #print() 203 | #print(transformers) 204 | # names = [x[1].named_steps for x in transformers] 205 | # 206 | # has_pca = False 207 | # has_one_hot = False 208 | # 209 | # for dictionary in names: 210 | # for value in dictionary.values(): 211 | # if isinstance(value,PCA): 212 | # has_pca = True 213 | # if isinstance(value,OneHotEncoder): 214 | # has_one_hot=True 215 | # 216 | # print(self.one_hot_features, has_pca, has_one_hot) 217 | 218 | if self.one_hot_features: 219 | try: 220 | ohe = (self.mdl.named_steps['preprocess'].named_transformers_['cat'].named_steps['onehot']) 221 | one_hot_feature_names = ohe.get_feature_names(input_features=self.one_hot_features) 222 | all_feature_names = np.r_[self.numeric_features, one_hot_feature_names, self.categorical_features] 223 | except: 224 | all_feature_names = self.predictors 225 | # Otherwise the features are in order 226 | else: 227 | all_feature_names = self.predictors 228 | print(len(self.mdl.named_steps['learn'].feature_importances_)) 229 | # Merge feature importances and names, save to file 230 | # try: 231 | # feature_importances = self.mdl.named_steps['learn'].feature_importances_ 232 | # feature_dictionary = {'Feature Names':all_feature_names,'Importances':feature_importances} 233 | # dictionary = pd.DataFrame(feature_dictionary) 234 | # dictionary = dictionary.sort_values(by='Importances', axis=0, ascending=False, na_position='last') 235 | # dictionary.to_csv(feature_importance_filename,index=0) 236 | # except Exception as e: 237 | # print('No feature importances collected, reporting exception: ', e) 238 | 239 | 240 | def predict_data(self, df, out_file, name, other_columns=[],dropna=True): 241 | """ 242 | Uses trained model to predict accuracy over inputted data that has the response variable to asses score, such as training, validation, or test set. 243 | Saves coordinates, true response variable, predicted response variable, residual, and copies of other_columns (if included) into out_file 244 | Calculates the RMSE, R-Squared, average residual, and average absolute residual for scores. 245 | 246 | Inputs: 247 | df (DataFrame): Dataframe of data to predict over containing predictors and y_column 248 | out_file (string): File name to save data with predictions to 249 | name (string): Name of dataset to save scores using "save_scores" method, examples could be "training", "testing", or "validation" 250 | other_columns (list): Other columns that should also be included, this could be a unique ID of datapoints 251 | dropna (boolean): Whether to remove records with any nan values. If set to False and NaN values are not resolved, this will cause an error. 252 | 253 | Returns: None 254 | """ 255 | # Prepare output dataframe with columns 256 | if len(other_columns)>0: 257 | out_df = pd.DataFrame(columns=self.xy+other_columns+['Y_true','Est','Residual']) 258 | else: 259 | out_df = pd.DataFrame(columns=self.xy+['Y_true','Est','Residual']) 260 | out_df.to_csv(out_file,index=False) 261 | 262 | # Remove records with NaN values if dropna is tru 263 | if dropna: 264 | df = df.dropna() 265 | 266 | # Predict and calculate residual 267 | #print(df[self.predictors]) 268 | y_hat = self.mdl.predict(df[self.predictors]) 269 | residual = df[self.y_column].values - y_hat 270 | 271 | # Create series with data 272 | dfY = pd.Series(df[self.y_column].values, name='Y_true') 273 | dfY_hat = pd.Series(y_hat, name='Est') 274 | dfResidual = pd.Series(residual, name='Residual') 275 | dfCoords = df[self.xy].reset_index(drop=True) 276 | 277 | # If other_columns are listed, merge all of this data and output 278 | if len(other_columns)>0: 279 | dfOtherVariables = df[other_columns].reset_index(drop=True) 280 | df0 = pd.concat([dfCoords, dfOtherVariables, dfY, dfY_hat, dfResidual], axis=1) 281 | out_df = pd.DataFrame(df0, columns=self.xy+other_columns+['Y_true','Est','Residual']) 282 | out_df.to_csv(out_file, mode='a', header=False, index=False) 283 | # Otherwise merge all the data and output 284 | else: 285 | df0 = pd.concat([dfCoords, dfY, dfY_hat, dfResidual], axis=1) 286 | out_df = pd.DataFrame(df0, columns=self.xy+['Y_true','Est','Residual']) 287 | out_df.to_csv(out_file, mode='a', header=False, index=False) 288 | 289 | # Calculate scores and save as parameters to ForestLearn to output in "save_scores" 290 | self.rmse[name] = math.sqrt(metrics.mean_squared_error(df[self.y_column], y_hat)) 291 | self.r2[name] = metrics.r2_score(df[self.y_column], y_hat) 292 | self.avg_res[name] = np.mean(df[self.y_column] - y_hat) 293 | self.avg_abs_res[name] = np.mean(abs(df[self.y_column] - y_hat)) 294 | 295 | 296 | def save_scores(self, out_file): 297 | """ 298 | Saves scores from predict_data 299 | 300 | Inputs: 301 | out_file (string): File name to save scores to 302 | 303 | Returns: None 304 | """ 305 | # Create dictionary and save 306 | dict_list = [self.rmse, self.r2, self.avg_res, self.avg_abs_res] 307 | df = pd.DataFrame(dict_list) 308 | df.insert(0, 'Scores', ['Root Mean Square Error','R-Squared','Average Residual','Average Absolute Residual']) 309 | df.to_csv(out_file,index=False) 310 | 311 | def predict_unsupervised_data(self, in_file, out_file, chunksize=500000, dropna=True): 312 | """ 313 | Uses trained model to predict over data from in_file and saves output to out_file 314 | 315 | Inputs: 316 | in_file (String): File name to load data from 317 | out_file (string): File name to save data with predictions to 318 | chunksize (integer): Chunk size to read data as, this is helpfull if the data is larger than memory can read 319 | dropna (boolean): Whether to remove records with any nan values. If set to False and NaN values are not resolved, this will cause an error. 320 | 321 | Returns: None 322 | """ 323 | # Prepare output dataframe 324 | out_df = pd.DataFrame(columns=self.xy+['Est']) 325 | out_df.to_csv(out_file,index=False) 326 | 327 | # Read in file using extension 328 | if '.csv' in in_file: 329 | chunks = pd.read_csv(in_file, chunksize=chunksize) 330 | else: 331 | chunks = pd.read_hdf(in_file, chunksize=chunksize) 332 | 333 | # Loop over chunks 334 | for df in chunks: 335 | # Remove records with NaN values if dropna is tru 336 | if dropna: 337 | df = df.dropna() 338 | # Predict data 339 | y_hat = self.mdl.predict(df[self.predictors]) 340 | # Save results 341 | dfY_hat = pd.Series(y_hat, name='Est').reset_index(drop=True) 342 | dfCoords = df[self.xy].reset_index(drop=True) 343 | df0 = pd.concat([dfCoords, dfY_hat, dfProb], axis=1) 344 | out_df = pd.DataFrame(df0, columns=self.xy+['Est']) 345 | out_df.to_csv(out_file, mode='a', header=False, index=False) 346 | 347 | 348 | ''' 349 | The following methods are for instatiating model pipelines, which creates steps for numeric feature scaling, one hot encoding, and feature selection. 350 | Learn more about the sci-kit learn model pipelines here: https://scikit-learn.org/stable/modules/generated/sklearn.pipeline.Pipeline.html 351 | We have a number of different ones precoded to use 352 | ''' 353 | 354 | def setup_rf_model(self): 355 | ''' 356 | Sets up a random forest model with no feature selection or scaling 357 | 358 | Returns: 359 | self.mdl (Sk-learn Pipeline object) 360 | ''' 361 | mdl1 = RandomForestRegressor( 362 | n_estimators=500, 363 | max_features="sqrt", 364 | min_samples_split=5, 365 | oob_score=True, 366 | ) 367 | 368 | estimators = [ 369 | ('learn', mdl1) 370 | ] 371 | self.mdl = Pipeline(estimators) 372 | return self.mdl 373 | 374 | 375 | def setup_rf_model_scale(self): 376 | ''' 377 | Sets up a random forest model with numeric feature scaling and one-hot-encoding 378 | 379 | Returns: 380 | self.mdl (Sk-learn Pipeline object) 381 | ''' 382 | numeric_transformer = Pipeline(steps=[ 383 | ('scale', StandardScaler())]) 384 | 385 | categorical_transformer = Pipeline(steps=[ 386 | ('onehot', OneHotEncoder(handle_unknown='ignore'))]) 387 | 388 | preprocessor = ColumnTransformer( 389 | transformers=[ 390 | ('num', numeric_transformer, self.numeric_features), 391 | ('cat', categorical_transformer, self.one_hot_features)],remainder='passthrough') 392 | 393 | mdl1 = RandomForestRegressor( 394 | n_estimators=500, 395 | max_features="sqrt", 396 | min_samples_split=5, 397 | oob_score=True, 398 | ) 399 | estimators = [ 400 | ('preprocess', preprocessor), 401 | ('learn', mdl1) 402 | ] 403 | self.mdl = Pipeline(estimators) 404 | return self.mdl 405 | 406 | def setup_rf_model_PCA(self): 407 | ''' 408 | Sets up a random forest model with numeric feature scaling, one-hot-encoding, and principle component analysis 409 | 410 | Returns: 411 | self.mdl (Sk-learn Pipeline object) 412 | ''' 413 | numeric_transformer = Pipeline(steps=[ 414 | ('scale', StandardScaler()), 415 | ('PCA', PCA(0.95))]) 416 | 417 | categorical_transformer = Pipeline(steps=[ 418 | ('onehot', OneHotEncoder(handle_unknown='ignore'))]) 419 | 420 | preprocessor = ColumnTransformer( 421 | transformers=[ 422 | ('num', numeric_transformer, self.numeric_features), 423 | ('cat', categorical_transformer, self.one_hot_features)],remainder='passthrough') 424 | 425 | mdl1 = RandomForestRegressor( 426 | n_estimators=500, 427 | max_features="sqrt", 428 | min_samples_split=5, 429 | oob_score=True, 430 | ) 431 | estimators = [ 432 | ('preprocess', preprocessor), 433 | ('learn', mdl1) 434 | ] 435 | self.mdl = Pipeline(estimators) 436 | return self.mdl 437 | 438 | 439 | def setup_rf_model_scale_SVR_FS(self): 440 | ''' 441 | Sets up a random forest model with numeric feature scaling, one-hot-encoding, and support vector machine feature selection 442 | 443 | Returns: 444 | self.mdl (Sk-learn Pipeline object) 445 | ''' 446 | numeric_transformer = Pipeline(steps=[ 447 | ('scale', StandardScaler())]) 448 | 449 | categorical_transformer = Pipeline(steps=[ 450 | ('onehot', OneHotEncoder(handle_unknown='ignore'))]) 451 | 452 | preprocessor = ColumnTransformer( 453 | transformers=[ 454 | ('num', numeric_transformer, self.numeric_features), 455 | ('cat', categorical_transformer, self.one_hot_features)],remainder='passthrough') 456 | 457 | mdl1 = RandomForestRegressor( 458 | n_estimators=500, 459 | max_features="sqrt", 460 | min_samples_split=5, 461 | oob_score=True, 462 | ) 463 | estimators = [ 464 | ('preprocess', preprocessor), 465 | ('feature_selection', SelectFromModel(LinearSVR())), 466 | ('learn', mdl1) 467 | ] 468 | self.mdl = Pipeline(estimators) 469 | return self.mdl 470 | 471 | def setup_rf_model_scale_RF_FS(self): 472 | ''' 473 | Sets up a random forest model with numeric feature scaling, one-hot-encoding, and random forest model feature selection 474 | 475 | Returns: 476 | self.mdl (Sk-learn Pipeline object) 477 | ''' 478 | numeric_transformer = Pipeline(steps=[ 479 | ('scale', StandardScaler())]) 480 | 481 | categorical_transformer = Pipeline(steps=[ 482 | ('onehot', OneHotEncoder(handle_unknown='ignore'))]) 483 | 484 | preprocessor = ColumnTransformer( 485 | transformers=[ 486 | ('num', numeric_transformer, self.numeric_features), 487 | ('cat', categorical_transformer, self.one_hot_features)],remainder='passthrough') 488 | 489 | mdl1 = RandomForestRegressor( 490 | n_estimators=500, 491 | max_features="sqrt", 492 | min_samples_split=5, 493 | oob_score=True, 494 | ) 495 | estimators = [ 496 | ('preprocess', preprocessor), 497 | ('feature_selection', SelectFromModel(RandomForestRegressor(n_estimators=100))), 498 | ('learn', mdl1) 499 | ] 500 | self.mdl = Pipeline(estimators) 501 | return self.mdl 502 | 503 | 504 | def setup_xgb_model(self): 505 | ''' 506 | Sets up a XGBoost model 507 | 508 | Returns: 509 | self.mdl (Sk-learn Pipeline object) 510 | ''' 511 | mdl1 = xgb.XGBRegressor( 512 | learning_rate=0.1, 513 | n_estimators=50, 514 | objective='reg:squarederror', 515 | eval_metric='rmse', 516 | nthread=-1) 517 | 518 | estimators = [ 519 | ('learn', mdl1) 520 | ] 521 | self.mdl = Pipeline(estimators) 522 | return self.mdl 523 | 524 | def setup_xgb_model_scale(self): 525 | ''' 526 | Sets up a XGBoost model with numeric feature scaling and one-hot-encoding 527 | 528 | Returns: 529 | self.mdl (Sk-learn Pipeline object) 530 | ''' 531 | numeric_transformer = Pipeline(steps=[('scale', StandardScaler())]) 532 | 533 | categorical_transformer = Pipeline(steps=[ 534 | ('onehot', OneHotEncoder(handle_unknown='ignore'))]) 535 | 536 | preprocessor = ColumnTransformer( 537 | transformers=[ 538 | ('num', numeric_transformer, self.numeric_features), 539 | ('cat', categorical_transformer, self.one_hot_features)],remainder='passthrough') 540 | 541 | mdl1 = xgb.XGBRegressor( 542 | learning_rate=0.1, 543 | n_estimators=50, 544 | objective='reg:squarederror', 545 | eval_metric='rmse', 546 | nthread=-1) 547 | 548 | estimators = [ 549 | ('preprocess', preprocessor), 550 | ('learn', mdl1) 551 | ] 552 | self.mdl = Pipeline(estimators) 553 | return self.mdl 554 | 555 | def setup_xgb_model_PCA(self): 556 | ''' 557 | Sets up a XGBoost model with numeric feature scaling, one-hot-encoding, and principle component analysis 558 | 559 | Returns: 560 | self.mdl (Sk-learn Pipeline object) 561 | ''' 562 | numeric_transformer = Pipeline(steps=[ 563 | ('scale', StandardScaler()), 564 | ('PCA', PCA(0.95)) 565 | ]) 566 | 567 | categorical_transformer = Pipeline(steps=[ 568 | ('onehot', OneHotEncoder(handle_unknown='ignore'))]) 569 | 570 | preprocessor = ColumnTransformer( 571 | transformers=[ 572 | ('num', numeric_transformer, self.numeric_features), 573 | ('cat', categorical_transformer, self.one_hot_features)],remainder='passthrough') 574 | 575 | mdl1 = xgb.XGBRegressor( 576 | learning_rate=0.1, 577 | n_estimators=50, 578 | objective='reg:squarederror', 579 | eval_metric='rmse', 580 | nthread=-1) 581 | 582 | estimators = [ 583 | ('preprocess', preprocessor), 584 | ('learn', mdl1) 585 | ] 586 | self.mdl = Pipeline(estimators) 587 | return self.mdl 588 | 589 | def setup_xgb_model_RF_FS(self): 590 | ''' 591 | Sets up a XGBoost model with numeric feature scaling, one-hot-encoding, and random forest feature selection 592 | 593 | Returns: 594 | self.mdl (Sk-learn Pipeline object) 595 | ''' 596 | numeric_transformer = Pipeline(steps=[('scale', StandardScaler())]) 597 | 598 | categorical_transformer = Pipeline(steps=[ 599 | ('onehot', OneHotEncoder(handle_unknown='ignore'))]) 600 | 601 | preprocessor = ColumnTransformer( 602 | transformers=[ 603 | ('num', numeric_transformer, self.numeric_features), 604 | ('cat', categorical_transformer, self.one_hot_features)],remainder='passthrough') 605 | 606 | 607 | mdl1 = xgb.XGBRegressor( 608 | learning_rate=0.1, 609 | n_estimators=50, 610 | objective='reg:squarederror', 611 | eval_metric='rmse', 612 | nthread=-1) 613 | 614 | estimators = [ 615 | ('preprocess', preprocessor), 616 | ('feature_selection', SelectFromModel(RandomForestRegressor(n_estimators=100))), 617 | ('learn', mdl1) 618 | ] 619 | self.mdl = Pipeline(estimators) 620 | return self.mdl 621 | 622 | 623 | -------------------------------------------------------------------------------- /MappingGlobalCarbon/gfw_forestlearn/geo_processing.py: -------------------------------------------------------------------------------- 1 | import pandas as pd 2 | import numpy as np 3 | import os 4 | from sklearn.model_selection import train_test_split 5 | import geopandas as gpd 6 | from geopandas import GeoDataFrame 7 | from shapely.geometry import Point 8 | import rasterio 9 | import multiprocessing as mp 10 | from multiprocessing import Pool # Process pool 11 | from multiprocessing import sharedctypes 12 | import tqdm 13 | 14 | def raster_clip(mask_file, in_file, out_file, resampling_method='near', out_format='Float32', 15 | srcnodata='nan', dstnodata='nan', max_memory='2000'): 16 | """ 17 | From learn2map 18 | for every input in_file, get the same spatial resolution, projection, and 19 | extent as the input mask_file. 20 | 21 | output is a new raster file: out_file. 22 | """ 23 | in0 = gdal.Open(mask_file) 24 | prj0 = in0.GetProjection() 25 | extent0, res0 = get_raster_extent(in0) 26 | extent0 = ' '.join(map(str, extent0)) 27 | res0 = ' '.join(map(str, res0)) 28 | size0 = '{} {}'.format(str(in0.RasterXSize), str(in0.RasterYSize)) 29 | 30 | in1 = gdal.Open(in_file) 31 | prj1 = in1.GetProjection() 32 | extent1, res1 = get_raster_extent(in1) 33 | extent1 = ' '.join(map(str, extent1)) 34 | res1 = ' '.join(map(str, res1)) 35 | 36 | if (out_format=='Float32') or (out_format=='Float64'): 37 | predictor_num = 3 38 | else: 39 | predictor_num = 2 40 | gdal_expression = ( 41 | 'gdalwarp -t_srs {} -te {} -ts {} ' 42 | '-srcnodata {} -dstnodata {} -multi -overwrite ' 43 | '-co COMPRESS=LZW -co PREDICTOR={} -co BIGTIFF=YES ' 44 | '-r {} -ot {} "{}" "{}"').format( 45 | prj0, extent0, size0, srcnodata, dstnodata, predictor_num, 46 | resampling_method, out_format, in_file, out_file) 47 | print(gdal_expression) 48 | subprocess.check_output(gdal_expression, shell=True) 49 | in0 = None 50 | in1 = None 51 | return 52 | 53 | def rasterize_shapefile(shapefile, mask_file, outfile, layer_name, burn_value=1, nodata_val=0, out_format='Byte', 54 | at=True,srcnodata=255, max_memory='2000'): 55 | """ 56 | rasterize shapefile to same projection as mask_file 57 | """ 58 | in0 = gdal.Open(mask_file) 59 | prj0 = in0.GetProjection() 60 | extent0, res0 = rt.get_raster_extent(in0) 61 | extent0 = ' '.join(map(str, extent0)) 62 | res0 = ' '.join(map(str, res0)) 63 | size0 = '{} {}'.format(str(in0.RasterXSize), str(in0.RasterYSize)) 64 | 65 | if at==True: 66 | gdal_expression = ( 67 | 'gdal_rasterize -burn {} -at -a_srs {} -te {} -ts {} -tr {} ' 68 | '-l {} -a_nodata {} -ot {} -co COMPRESS=LZW -co NUM_THREADS=ALL_CPUS ' 69 | '"{}" "{}"').format(burn_value, prj0, extent0, size0, res0, layer_name, nodata_val, out_format, shapefile, outfile) 70 | else: 71 | gdal_expression = ( 72 | 'gdal_rasterize -burn {} -a_srs {} -te {} -ts {} -tr {} ' 73 | '-l {} -a_nodata {} -ot {} -co COMPRESS=LZW -co NUM_THREADS=ALL_CPUS ' 74 | '"{}" "{}"').format(burn_value, prj0, extent0, size0, res0, layer_name, nodata_val, out_format, shapefile, outfile) 75 | print(gdal_expression) 76 | subprocess.check_output(gdal_expression, shell=True) 77 | in0 = None 78 | in1 = None 79 | return 80 | 81 | def build_stack_vrt(in_file_list, out_file): 82 | """ 83 | build raster stack vrt file from in_file_list. 84 | :param in_file_list: 85 | :param out_file: output vrt file (end with .vrt) 86 | :return: 87 | """ 88 | gdal_expression_01 = ( 89 | 'gdalbuildvrt -separate -overwrite -input_file_list "{}" "{}" --config GDAL_CACHEMAX 2000' 90 | ).format(in_file_list, out_file) 91 | subprocess.check_output(gdal_expression_01, shell=True) 92 | field_names = modify_vrt_xml(out_file) 93 | print(field_names) 94 | 95 | return field_names 96 | 97 | def raster_to_h5(in_file_vrt, out_file_h5, field_names, mask_column, mask_valid_range=0, lines=100, drop_nan=True): 98 | """ 99 | Make a layer stack of raster bands to be used in csv output. 100 | Output is a virtual raster with all bands and csv files with geolocation and valid data. 101 | All layers should be processed to have the same geolocation and dimensions. 102 | Mask band should be the 1st band in the in_file_list 103 | :param in_file_vrt: file name of the input virtual raster files 104 | :param out_file_h5: file name of output h5 file 105 | :param field_names: names of all columns 106 | :param mask_column: column used to mask data 107 | :param mask_valid_range: define valid data range (e.g.: >0) in mask band 108 | :param lines: numbers of lines to read at once 109 | :return: None 110 | """ 111 | in0 = gdal.Open(in_file_vrt) 112 | bands = [] 113 | for band_num in range(in0.RasterCount): 114 | band_num += 1 115 | band = in0.GetRasterBand(band_num) 116 | bands.append(band) 117 | dim0 = (0, 0, in0.RasterXSize, in0.RasterYSize) 118 | gt = in0.GetGeoTransform() 119 | 120 | with pd.HDFStore(out_file_h5, mode='w', complib='blosc:snappy', complevel=9) as store: 121 | for y in range(dim0[1], dim0[3], lines): 122 | y2 = min(y + lines, dim0[3]) 123 | lines1 = y2 - y 124 | cols, rows = np.meshgrid(np.arange(dim0[2]), np.arange(y, y2)) 125 | geo_x = gt[0] + (cols + 0.5) * gt[1] + (rows + 0.5) * gt[2] 126 | geo_y = gt[3] + (cols + 0.5) * gt[4] + (rows + 0.5) * gt[5] 127 | data = np.vstack((geo_x.flatten(), geo_y.flatten())) 128 | for band in bands: 129 | band_data = band.ReadAsArray(dim0[0], y, dim0[2] - dim0[0], lines1).flatten() 130 | data = np.vstack((data, band_data)) 131 | if drop_nan is True: 132 | df1 = pd.DataFrame(data, dtype='float32').transpose().dropna() 133 | else: 134 | df1 = pd.DataFrame(data, dtype='float32').transpose() 135 | df1.columns = ['x', 'y'] + field_names 136 | df0 = df1.loc[lambda df: df[mask_column] > mask_valid_range, :] 137 | store.append('df0', df0, index=False, data_columns=df0.columns) 138 | with pd.HDFStore(out_file_h5) as store: 139 | store.create_table_index('df0', columns=['x', 'y'], optlevel=6, kind='medium') 140 | in0 = None 141 | return 142 | 143 | def convert_hdf(in_file_list,out_file_name): 144 | with open(in_file_list, 'r') as f: 145 | file_names = f.readlines() 146 | mask_column = '{}_b1'.format(os.path.basename(os.path.splitext(file_names[0])[0])) 147 | y_column = '{}_b1'.format(os.path.basename(os.path.splitext(file_names[1])[0])) 148 | out_vrt = '{}.vrt'.format(out_file_name) 149 | print(out_vrt) 150 | field_names = rt.build_stack_vrt(in_file_list, out_vrt) 151 | out_h5 = '{}.h5'.format(out_file_name) 152 | raster_to_h5(out_vrt, out_h5, field_names, mask_column, mask_valid_range=0, lines=1000, drop_nan=True) 153 | 154 | 155 | 156 | def get_reference_coordinates(df, reference_raster_file, in_lat_name='y', in_lon_name = 'x', out_lat_name = 'Lat_1km', out_lon_name = 'Lon_1km'): 157 | """ 158 | #Function to find the coordinates of a lower resolution raster 159 | """ 160 | out_df = df.copy() 161 | src = rasterio.open(reference_raster_file) 162 | metadata = src.meta 163 | for i,row in out_df.iterrows(): 164 | raster_row, raster_column = rasterio.transform.rowcol(metadata.get('transform'), row[in_lon_name], row[in_lat_name]) 165 | ref_coords = rasterio.transform.xy(metadata.get('transform'), raster_row, raster_column, offset='center') 166 | out_df.at[i,out_lon_name] = ref_coords[0] 167 | out_df.at[i,out_lat_name] = ref_coords[1] 168 | 169 | 170 | def stratify_split(df, stratify_column, test_size = 0.2): 171 | """ 172 | #Stratify split dataframe 173 | """ 174 | return train_test_split(df,stratify=df[stratify_column].values,test_size=test_size) 175 | 176 | 177 | def save_point_df_and_shp(df, out_prefix, x_field, y_field, out_crs='epsg:4326'): 178 | """ 179 | #Save plot as a CSV and SHP 180 | """ 181 | df.to_csv('{}.csv'.format(out_prefix),index=False) 182 | if not os.path.exists(out_prefix): 183 | os.mkdir(out_prefix) 184 | out_prefix = '{}/{}'.format(out_prefix,out_prefix) 185 | geometry = [Point(xy) for xy in zip(df[x_field].values, df[y_field].values)] 186 | crs = {'init': out_crs} 187 | gdf = GeoDataFrame(df.copy(), crs=crs, geometry=geometry) 188 | gdf.to_file('{}.shp'.format(out_prefix)) 189 | return None 190 | 191 | 192 | def average_plots_with_matching_coords(df, x_field, y_field): 193 | """ 194 | #Average plot values within matching coordinates (use after get_reference_coordinates) 195 | """ 196 | average_plots = pd.DataFrame(columns=list(df)) 197 | coordinates = df[[y_field,x_field]].drop_duplicates() 198 | print('Number of unique coordinates {}'.format(len(coordinates))) 199 | for i, row in coordinates.iterrows(): 200 | lat = row[y_field] 201 | lon = row[x_field] 202 | match_rows = df[(df[y_field]==lat)&(df[x_field]==lon)] 203 | new_row = match_rows.iloc[0].copy() 204 | if len(match_rows)>1: 205 | new_values = match_rows.mean(axis=0) 206 | new_row.replace(list(new_values),new_values) 207 | average_plots = average_plots.append(new_row, ignore_index = True) 208 | return average_plots 209 | 210 | 211 | def find_matching_plot_coords(unique_df,df, x_field, y_field): 212 | """ 213 | Find plots that are in the same pixel 214 | """ 215 | #unique_df = df[[x_field,y_field]].drop_duplicates() 216 | match_df = pd.DataFrame(columns=list(df)) 217 | for i, row in unique_df.iterrows(): 218 | lat = row[y_field] 219 | lon = row[x_field] 220 | match_rows = df[(df[y_field]==lat)&(df[x_field]==lon)] 221 | match_df = match_df.append(match_rows, ignore_index = True) 222 | return match_df 223 | 224 | 225 | def sample_raster_at_point_location(args): 226 | """ 227 | #Sample raster at point location 228 | """ 229 | coordinates = args[0] 230 | raster_file = args[1] 231 | with rasterio.open(raster_file) as src: 232 | num_bands = src.count 233 | raster_name = os.path.splitext(os.path.basename(raster_file))[0] 234 | band_names = [raster_name+'_b{}'.format(x) for x in np.arange(1,num_bands+1)] 235 | #columns = ['Coordinates']+band_names 236 | df = pd.DataFrame(columns=band_names) 237 | #df['Coordinates'] = coordinates 238 | try: 239 | length = sum(1 for _ in src.sample(coordinates)) 240 | except: 241 | length = 0 242 | if length>0: 243 | values = src.sample(coordinates) 244 | for i,val in enumerate(values): 245 | df.at[i,band_names] = val 246 | return df 247 | 248 | 249 | def get_covariates_at_point_locations(df, covariate_raster_list, x_name = 'x', y_name = 'y'): 250 | """ 251 | #Get covarates at point locations 252 | """ 253 | coords = df.copy() 254 | coords = coords[[x_name,y_name]].values 255 | coordinates = [tuple(x) for x in coords] 256 | args = [[coordinates, x] for x in covariate_raster_list] 257 | pool = mp.Pool() 258 | results = pool.map(sample_raster_at_point_location, args) 259 | results = [df]+results 260 | out_df = pd.concat(results, join="inner",axis=1,sort=False) 261 | return out_df 262 | 263 | 264 | # coords = [[-53.23123,48.95448],[-53.45, 48.94],[-53.66, 48.82], [-53.19, 48.54], [-53.68, 48.58]] 265 | # in_df = pd.DataFrame(columns=['x','y']) 266 | # in_df['x'] = [x[0] for x in coords] 267 | # in_df['y'] = [x[1] for x in coords] 268 | # print(in_df) 269 | # raster_list = ['/Users/kristine/Downloads/landsat_example.tif','/Users/kristine/Downloads/CM10_1975H_Bio20_V1_2.tif'] 270 | # out_df = get_covariates_at_point_locations(in_df, raster_list) 271 | # print(out_df) 272 | # out_df.to_csv('/Users/kristine/Downloads/covariate_sample_example.csv',index=False) 273 | # out = sample_raster_at_point_location([coords,raster_file]) 274 | # out['x'] = [x[0] for x in out['Coordinates'].values] 275 | # out['y'] = [x[1] for x in out['Coordinates'].values] 276 | # out_csv_name = '/Users/kristine/Downloads/landsat_example.csv' 277 | # out.to_csv(out_csv_name,index=False) 278 | # out_file = '/Users/kristine/Downloads/landsat_example_b1.tif' 279 | # parallel_write_csv_to_raster(out_csv_name, raster_file, 'landsat_example_b1',out_file) 280 | # print(out) 281 | 282 | 283 | # 284 | # class OtherClass: 285 | # def run(self, sentence, graph): 286 | # return False 287 | # 288 | # def single(params): 289 | # other = OtherClass() 290 | # sentences, graph = params 291 | # return [other.run(sentence, graph) for sentence in sentences] 292 | # 293 | # class SomeClass: 294 | # def __init__(self): 295 | # self.sentences = [["Some string"]] 296 | # self.graphs = ["string"] 297 | # def some_method(self): 298 | # return list(pool.map(single, zip(self.sentences, self.graphs))) 299 | # 300 | # if __name__ == '__main__': # <- prevent RuntimeError for 'spawn' 301 | # # and 'forkserver' start_methods 302 | # with multiprocessing.Pool(multiprocessing.cpu_count() - 1) as pool: 303 | # print(SomeClass().some_method()) 304 | # 305 | # def fill_per_window(sa, df, x='x',y='y'): 306 | # for i,row in df.iterrows(): 307 | # tmp = np.ctypeslib.as_array(sa) 308 | # index = src.index(row[x],row[y]) 309 | # print(index) 310 | # tmp[index] = row[target_column] 311 | # 312 | # def convert_csv_to_raster(in_csv, out_raster_name, reference_raster_name, x = 'x', y = 'y', chunksize = 1000000) 313 | # src = rasterio.open(reference_raster_name) 314 | # data = np.zeros((src.height,src.width)) 315 | # data[:,:] = np.nan 316 | # result = np.ctypeslib.as_ctypes(data) 317 | # shared_array = sharedctypes.RawArray(result._type_, result) 318 | # length = int(138950955/chunksize) 319 | # print('Entering pool') 320 | # p = Pool() 321 | # for _ in tqdm.tqdm(p.imap_unordered(fill_per_window, pd.read_csv(in_csv, chunksize=chunksize)), total=length): 322 | # pass 323 | # p.close() 324 | # p.join() 325 | # #res = p.map(fill_per_window, pd.read_csv(in_csv, chunksize=chunksize)) 326 | # result = np.ctypeslib.as_array(shared_array) 327 | # profile = src.profile 328 | # profile.update(dtype=rasterio.float32,count=1,compress='lzw') 329 | # with rasterio.open(out_file, 'w', **profile) as dst: 330 | # dst.write(result.astype(rasterio.float32), 1) 331 | # dst.nodata = np.nan 332 | # 333 | 334 | 335 | 336 | 337 | 338 | 339 | 340 | 341 | 342 | 343 | 344 | 345 | 346 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Global Reforestation Opportunity Assessment (GROA) 2 | 3 | [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.3983644.svg)](https://doi.org/10.5281/zenodo.3983644) 4 | 5 | These data were assembled by the Nature Conservancy and a team of scientists from 19 institutions to quantify carbon sequestration in naturally regenerating forests around the world. This analysis was published in *Nature* in 2020 (Cook-Patton et al. 2020). 6 | 7 | We encourage the research community to collaborate in updating, correcting, expanding, and utilizing this database through the GitHub platform. 8 | 9 | ### Relationship to ForC 10 | GROA identified relevant studies within the Global Forest Carbon database, [ForC](https://forc-db.github.io/), and tracked down the original studies to confirm or update the data. It is now hosted by the [ForC-db organization on GitHub](https://github.com/forc-db). This repository also contains [code and data files for integration of GROA into ForC](https://github.com/forc-db/GROA/tree/master/GROA-ForC_integration). 11 | 12 | ## Data Use Policy and Guidelines 13 | 14 | ### License 15 | 16 | GROA is licensed under [CC-BY-4](https://creativecommons.org/licenses/by/4.0/), as described in [`license.txt`](https://github.com/forc-db/GROA/blob/master/license.txt). 17 | 18 | ### Communication/ collaboration with GROA team 19 | 20 | While not required, we encourage researchers planning to use GROA to contact the principal investigator (Dr. Susan Cook-Patton, The Nature Conservancy) to inform her of intended use of the data and to discuss potential collaboration. 21 | 22 | ### Database citation 23 | Any publications using these data should cite Cook-Patton et al. 2020. 24 | 25 | In addition, this database should be referenced as well (DOI representing all versions: [10.5281/zenodo.3983644](https://doi.org/10.5281/zenodo.3983644)). If the data has changed since original publication, arising publications should cite the specific version used, ideally with a DOI associated with that version. Authors may contact Susan Cook-Patton (The Nature Conservancy) or Kristina Anderson-Teixeira (Smithsonian) to generate a release and associated DOI that matches the database version used. 26 | 27 | ## Citation 28 | Cook-Patton, S.C., S.M. Leavitt, D. Gibbs, N.L. Harris, K. Lister, K.J. Anderson-Teixeira, R.D. Briggs, R.L. Chazdon, T.W. Crowther, P.W. Ellis, H.P. Griscom, V. Herrmann, K.D. Holl, R.A. Houghton, C. Larrosa, G. Lomax, R. Lucas, P. Madsen, Y. Malhi, A. Paquette, J.D. Parker, K. Paul, D. Routh, S. Roxburgh, S. Saatchi, J. van den Hoogen, W.S. Walker, C. E. Wheeler, S. A. Wood, L. Xu, & B. W. Griscom (2020) Mapping Potential Carbon Capture from Global Natural Forest Regrowth. *Nature*, in press. 29 | 30 | 31 | 32 | ## Contacts 33 | Susan Cook-Patton, The Nature Conservancy 34 | 35 | Kristina Anderson-Teixeira, Smithsonian 36 | -------------------------------------------------------------------------------- /data/GROA literature.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/data/GROA literature.csv -------------------------------------------------------------------------------- /data/METADATA.5.June.2020.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/data/METADATA.5.June.2020.docx -------------------------------------------------------------------------------- /data/biomass_litter_CWD.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/data/biomass_litter_CWD.csv -------------------------------------------------------------------------------- /data/sites.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/forc-db/GROA/e3c8328aaa0a3845b5b04b092a5cce4a5090c16d/data/sites.csv -------------------------------------------------------------------------------- /license.txt: -------------------------------------------------------------------------------- 1 | Attribution 4.0 International 2 | 3 | ======================================================================= 4 | 5 | Creative Commons Corporation ("Creative Commons") is not a law firm and 6 | does not provide legal services or legal advice. Distribution of 7 | Creative Commons public licenses does not create a lawyer-client or 8 | other relationship. Creative Commons makes its licenses and related 9 | information available on an "as-is" basis. Creative Commons gives no 10 | warranties regarding its licenses, any material licensed under their 11 | terms and conditions, or any related information. Creative Commons 12 | disclaims all liability for damages resulting from their use to the 13 | fullest extent possible. 14 | 15 | Using Creative Commons Public Licenses 16 | 17 | Creative Commons public licenses provide a standard set of terms and 18 | conditions that creators and other rights holders may use to share 19 | original works of authorship and other material subject to copyright 20 | and certain other rights specified in the public license below. The 21 | following considerations are for informational purposes only, are not 22 | exhaustive, and do not form part of our licenses. 23 | 24 | Considerations for licensors: Our public licenses are 25 | intended for use by those authorized to give the public 26 | permission to use material in ways otherwise restricted by 27 | copyright and certain other rights. Our licenses are 28 | irrevocable. Licensors should read and understand the terms 29 | and conditions of the license they choose before applying it. 30 | Licensors should also secure all rights necessary before 31 | applying our licenses so that the public can reuse the 32 | material as expected. Licensors should clearly mark any 33 | material not subject to the license. This includes other CC- 34 | licensed material, or material used under an exception or 35 | limitation to copyright. More considerations for licensors: 36 | wiki.creativecommons.org/Considerations_for_licensors 37 | 38 | Considerations for the public: By using one of our public 39 | licenses, a licensor grants the public permission to use the 40 | licensed material under specified terms and conditions. If 41 | the licensor's permission is not necessary for any reason--for 42 | example, because of any applicable exception or limitation to 43 | copyright--then that use is not regulated by the license. Our 44 | licenses grant only permissions under copyright and certain 45 | other rights that a licensor has authority to grant. Use of 46 | the licensed material may still be restricted for other 47 | reasons, including because others have copyright or other 48 | rights in the material. A licensor may make special requests, 49 | such as asking that all changes be marked or described. 50 | Although not required by our licenses, you are encouraged to 51 | respect those requests where reasonable. More considerations 52 | for the public: 53 | wiki.creativecommons.org/Considerations_for_licensees 54 | 55 | ======================================================================= 56 | 57 | Creative Commons Attribution 4.0 International Public License 58 | 59 | By exercising the Licensed Rights (defined below), You accept and agree 60 | to be bound by the terms and conditions of this Creative Commons 61 | Attribution 4.0 International Public License ("Public License"). To the 62 | extent this Public License may be interpreted as a contract, You are 63 | granted the Licensed Rights in consideration of Your acceptance of 64 | these terms and conditions, and the Licensor grants You such rights in 65 | consideration of benefits the Licensor receives from making the 66 | Licensed Material available under these terms and conditions. 67 | 68 | 69 | Section 1 -- Definitions. 70 | 71 | a. Adapted Material means material subject to Copyright and Similar 72 | Rights that is derived from or based upon the Licensed Material 73 | and in which the Licensed Material is translated, altered, 74 | arranged, transformed, or otherwise modified in a manner requiring 75 | permission under the Copyright and Similar Rights held by the 76 | Licensor. For purposes of this Public License, where the Licensed 77 | Material is a musical work, performance, or sound recording, 78 | Adapted Material is always produced where the Licensed Material is 79 | synched in timed relation with a moving image. 80 | 81 | b. Adapter's License means the license You apply to Your Copyright 82 | and Similar Rights in Your contributions to Adapted Material in 83 | accordance with the terms and conditions of this Public License. 84 | 85 | c. Copyright and Similar Rights means copyright and/or similar rights 86 | closely related to copyright including, without limitation, 87 | performance, broadcast, sound recording, and Sui Generis Database 88 | Rights, without regard to how the rights are labeled or 89 | categorized. For purposes of this Public License, the rights 90 | specified in Section 2(b)(1)-(2) are not Copyright and Similar 91 | Rights. 92 | 93 | d. Effective Technological Measures means those measures that, in the 94 | absence of proper authority, may not be circumvented under laws 95 | fulfilling obligations under Article 11 of the WIPO Copyright 96 | Treaty adopted on December 20, 1996, and/or similar international 97 | agreements. 98 | 99 | e. Exceptions and Limitations means fair use, fair dealing, and/or 100 | any other exception or limitation to Copyright and Similar Rights 101 | that applies to Your use of the Licensed Material. 102 | 103 | f. Licensed Material means the artistic or literary work, database, 104 | or other material to which the Licensor applied this Public 105 | License. 106 | 107 | g. Licensed Rights means the rights granted to You subject to the 108 | terms and conditions of this Public License, which are limited to 109 | all Copyright and Similar Rights that apply to Your use of the 110 | Licensed Material and that the Licensor has authority to license. 111 | 112 | h. Licensor means the individual(s) or entity(ies) granting rights 113 | under this Public License. 114 | 115 | i. Share means to provide material to the public by any means or 116 | process that requires permission under the Licensed Rights, such 117 | as reproduction, public display, public performance, distribution, 118 | dissemination, communication, or importation, and to make material 119 | available to the public including in ways that members of the 120 | public may access the material from a place and at a time 121 | individually chosen by them. 122 | 123 | j. Sui Generis Database Rights means rights other than copyright 124 | resulting from Directive 96/9/EC of the European Parliament and of 125 | the Council of 11 March 1996 on the legal protection of databases, 126 | as amended and/or succeeded, as well as other essentially 127 | equivalent rights anywhere in the world. 128 | 129 | k. You means the individual or entity exercising the Licensed Rights 130 | under this Public License. Your has a corresponding meaning. 131 | 132 | 133 | Section 2 -- Scope. 134 | 135 | a. License grant. 136 | 137 | 1. Subject to the terms and conditions of this Public License, 138 | the Licensor hereby grants You a worldwide, royalty-free, 139 | non-sublicensable, non-exclusive, irrevocable license to 140 | exercise the Licensed Rights in the Licensed Material to: 141 | 142 | a. reproduce and Share the Licensed Material, in whole or 143 | in part; and 144 | 145 | b. produce, reproduce, and Share Adapted Material. 146 | 147 | 2. Exceptions and Limitations. For the avoidance of doubt, where 148 | Exceptions and Limitations apply to Your use, this Public 149 | License does not apply, and You do not need to comply with 150 | its terms and conditions. 151 | 152 | 3. Term. The term of this Public License is specified in Section 153 | 6(a). 154 | 155 | 4. Media and formats; technical modifications allowed. The 156 | Licensor authorizes You to exercise the Licensed Rights in 157 | all media and formats whether now known or hereafter created, 158 | and to make technical modifications necessary to do so. The 159 | Licensor waives and/or agrees not to assert any right or 160 | authority to forbid You from making technical modifications 161 | necessary to exercise the Licensed Rights, including 162 | technical modifications necessary to circumvent Effective 163 | Technological Measures. For purposes of this Public License, 164 | simply making modifications authorized by this Section 2(a) 165 | (4) never produces Adapted Material. 166 | 167 | 5. Downstream recipients. 168 | 169 | a. Offer from the Licensor -- Licensed Material. Every 170 | recipient of the Licensed Material automatically 171 | receives an offer from the Licensor to exercise the 172 | Licensed Rights under the terms and conditions of this 173 | Public License. 174 | 175 | b. No downstream restrictions. You may not offer or impose 176 | any additional or different terms or conditions on, or 177 | apply any Effective Technological Measures to, the 178 | Licensed Material if doing so restricts exercise of the 179 | Licensed Rights by any recipient of the Licensed 180 | Material. 181 | 182 | 6. No endorsement. Nothing in this Public License constitutes or 183 | may be construed as permission to assert or imply that You 184 | are, or that Your use of the Licensed Material is, connected 185 | with, or sponsored, endorsed, or granted official status by, 186 | the Licensor or others designated to receive attribution as 187 | provided in Section 3(a)(1)(A)(i). 188 | 189 | b. Other rights. 190 | 191 | 1. Moral rights, such as the right of integrity, are not 192 | licensed under this Public License, nor are publicity, 193 | privacy, and/or other similar personality rights; however, to 194 | the extent possible, the Licensor waives and/or agrees not to 195 | assert any such rights held by the Licensor to the limited 196 | extent necessary to allow You to exercise the Licensed 197 | Rights, but not otherwise. 198 | 199 | 2. Patent and trademark rights are not licensed under this 200 | Public License. 201 | 202 | 3. To the extent possible, the Licensor waives any right to 203 | collect royalties from You for the exercise of the Licensed 204 | Rights, whether directly or through a collecting society 205 | under any voluntary or waivable statutory or compulsory 206 | licensing scheme. In all other cases the Licensor expressly 207 | reserves any right to collect such royalties. 208 | 209 | 210 | Section 3 -- License Conditions. 211 | 212 | Your exercise of the Licensed Rights is expressly made subject to the 213 | following conditions. 214 | 215 | a. Attribution. 216 | 217 | 1. If You Share the Licensed Material (including in modified 218 | form), You must: 219 | 220 | a. retain the following if it is supplied by the Licensor 221 | with the Licensed Material: 222 | 223 | i. identification of the creator(s) of the Licensed 224 | Material and any others designated to receive 225 | attribution, in any reasonable manner requested by 226 | the Licensor (including by pseudonym if 227 | designated); 228 | 229 | ii. a copyright notice; 230 | 231 | iii. a notice that refers to this Public License; 232 | 233 | iv. a notice that refers to the disclaimer of 234 | warranties; 235 | 236 | v. a URI or hyperlink to the Licensed Material to the 237 | extent reasonably practicable; 238 | 239 | b. indicate if You modified the Licensed Material and 240 | retain an indication of any previous modifications; and 241 | 242 | c. indicate the Licensed Material is licensed under this 243 | Public License, and include the text of, or the URI or 244 | hyperlink to, this Public License. 245 | 246 | 2. You may satisfy the conditions in Section 3(a)(1) in any 247 | reasonable manner based on the medium, means, and context in 248 | which You Share the Licensed Material. For example, it may be 249 | reasonable to satisfy the conditions by providing a URI or 250 | hyperlink to a resource that includes the required 251 | information. 252 | 253 | 3. If requested by the Licensor, You must remove any of the 254 | information required by Section 3(a)(1)(A) to the extent 255 | reasonably practicable. 256 | 257 | 4. If You Share Adapted Material You produce, the Adapter's 258 | License You apply must not prevent recipients of the Adapted 259 | Material from complying with this Public License. 260 | 261 | 262 | Section 4 -- Sui Generis Database Rights. 263 | 264 | Where the Licensed Rights include Sui Generis Database Rights that 265 | apply to Your use of the Licensed Material: 266 | 267 | a. for the avoidance of doubt, Section 2(a)(1) grants You the right 268 | to extract, reuse, reproduce, and Share all or a substantial 269 | portion of the contents of the database; 270 | 271 | b. if You include all or a substantial portion of the database 272 | contents in a database in which You have Sui Generis Database 273 | Rights, then the database in which You have Sui Generis Database 274 | Rights (but not its individual contents) is Adapted Material; and 275 | 276 | c. You must comply with the conditions in Section 3(a) if You Share 277 | all or a substantial portion of the contents of the database. 278 | 279 | For the avoidance of doubt, this Section 4 supplements and does not 280 | replace Your obligations under this Public License where the Licensed 281 | Rights include other Copyright and Similar Rights. 282 | 283 | 284 | Section 5 -- Disclaimer of Warranties and Limitation of Liability. 285 | 286 | a. UNLESS OTHERWISE SEPARATELY UNDERTAKEN BY THE LICENSOR, TO THE 287 | EXTENT POSSIBLE, THE LICENSOR OFFERS THE LICENSED MATERIAL AS-IS 288 | AND AS-AVAILABLE, AND MAKES NO REPRESENTATIONS OR WARRANTIES OF 289 | ANY KIND CONCERNING THE LICENSED MATERIAL, WHETHER EXPRESS, 290 | IMPLIED, STATUTORY, OR OTHER. THIS INCLUDES, WITHOUT LIMITATION, 291 | WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR 292 | PURPOSE, NON-INFRINGEMENT, ABSENCE OF LATENT OR OTHER DEFECTS, 293 | ACCURACY, OR THE PRESENCE OR ABSENCE OF ERRORS, WHETHER OR NOT 294 | KNOWN OR DISCOVERABLE. WHERE DISCLAIMERS OF WARRANTIES ARE NOT 295 | ALLOWED IN FULL OR IN PART, THIS DISCLAIMER MAY NOT APPLY TO YOU. 296 | 297 | b. TO THE EXTENT POSSIBLE, IN NO EVENT WILL THE LICENSOR BE LIABLE 298 | TO YOU ON ANY LEGAL THEORY (INCLUDING, WITHOUT LIMITATION, 299 | NEGLIGENCE) OR OTHERWISE FOR ANY DIRECT, SPECIAL, INDIRECT, 300 | INCIDENTAL, CONSEQUENTIAL, PUNITIVE, EXEMPLARY, OR OTHER LOSSES, 301 | COSTS, EXPENSES, OR DAMAGES ARISING OUT OF THIS PUBLIC LICENSE OR 302 | USE OF THE LICENSED MATERIAL, EVEN IF THE LICENSOR HAS BEEN 303 | ADVISED OF THE POSSIBILITY OF SUCH LOSSES, COSTS, EXPENSES, OR 304 | DAMAGES. WHERE A LIMITATION OF LIABILITY IS NOT ALLOWED IN FULL OR 305 | IN PART, THIS LIMITATION MAY NOT APPLY TO YOU. 306 | 307 | c. The disclaimer of warranties and limitation of liability provided 308 | above shall be interpreted in a manner that, to the extent 309 | possible, most closely approximates an absolute disclaimer and 310 | waiver of all liability. 311 | 312 | 313 | Section 6 -- Term and Termination. 314 | 315 | a. This Public License applies for the term of the Copyright and 316 | Similar Rights licensed here. However, if You fail to comply with 317 | this Public License, then Your rights under this Public License 318 | terminate automatically. 319 | 320 | b. Where Your right to use the Licensed Material has terminated under 321 | Section 6(a), it reinstates: 322 | 323 | 1. automatically as of the date the violation is cured, provided 324 | it is cured within 30 days of Your discovery of the 325 | violation; or 326 | 327 | 2. upon express reinstatement by the Licensor. 328 | 329 | For the avoidance of doubt, this Section 6(b) does not affect any 330 | right the Licensor may have to seek remedies for Your violations 331 | of this Public License. 332 | 333 | c. For the avoidance of doubt, the Licensor may also offer the 334 | Licensed Material under separate terms or conditions or stop 335 | distributing the Licensed Material at any time; however, doing so 336 | will not terminate this Public License. 337 | 338 | d. Sections 1, 5, 6, 7, and 8 survive termination of this Public 339 | License. 340 | 341 | 342 | Section 7 -- Other Terms and Conditions. 343 | 344 | a. The Licensor shall not be bound by any additional or different 345 | terms or conditions communicated by You unless expressly agreed. 346 | 347 | b. Any arrangements, understandings, or agreements regarding the 348 | Licensed Material not stated herein are separate from and 349 | independent of the terms and conditions of this Public License. 350 | 351 | 352 | Section 8 -- Interpretation. 353 | 354 | a. For the avoidance of doubt, this Public License does not, and 355 | shall not be interpreted to, reduce, limit, restrict, or impose 356 | conditions on any use of the Licensed Material that could lawfully 357 | be made without permission under this Public License. 358 | 359 | b. To the extent possible, if any provision of this Public License is 360 | deemed unenforceable, it shall be automatically reformed to the 361 | minimum extent necessary to make it enforceable. If the provision 362 | cannot be reformed, it shall be severed from this Public License 363 | without affecting the enforceability of the remaining terms and 364 | conditions. 365 | 366 | c. No term or condition of this Public License will be waived and no 367 | failure to comply consented to unless expressly agreed to by the 368 | Licensor. 369 | 370 | d. Nothing in this Public License constitutes or may be interpreted 371 | as a limitation upon, or waiver of, any privileges and immunities 372 | that apply to the Licensor or You, including from the legal 373 | processes of any jurisdiction or authority. 374 | 375 | 376 | ======================================================================= 377 | 378 | Creative Commons is not a party to its public licenses. 379 | Notwithstanding, Creative Commons may elect to apply one of its public 380 | licenses to material it publishes and in those instances will be 381 | considered the “Licensor.” The text of the Creative Commons public 382 | licenses is dedicated to the public domain under the CC0 Public Domain 383 | Dedication. Except for the limited purpose of indicating that material 384 | is shared under a Creative Commons public license or as otherwise 385 | permitted by the Creative Commons policies published at 386 | creativecommons.org/policies, Creative Commons does not authorize the 387 | use of the trademark "Creative Commons" or any other trademark or logo 388 | of Creative Commons without its prior written consent including, 389 | without limitation, in connection with any unauthorized modifications 390 | to any of its public licenses or any other arrangements, 391 | understandings, or agreements concerning use of licensed material. For 392 | the avoidance of doubt, this paragraph does not form part of the public 393 | licenses. 394 | 395 | Creative Commons may be contacted at creativecommons.org. 396 | --------------------------------------------------------------------------------