Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SRDB import cleanup #178

Closed
8 of 9 tasks
teixeirak opened this issue May 10, 2019 · 20 comments
Closed
8 of 9 tasks

SRDB import cleanup #178

teixeirak opened this issue May 10, 2019 · 20 comments

Comments

@teixeirak
Copy link
Member

teixeirak commented May 10, 2019

Here's a running list of things to check/ fix:

  • Some plot names repeat "Stand established around [YEAR]"
  • Some plot names include "Stand established around NA"
  • Plot name "Unmanaged Mature Temperate Evergreen Forest with Clearcut treatment. Stand established around 1980" and any similar ("Clearcut treatment" doesn't make sense) - see issue clarify meaning of "Clearcut" manipulation in relation to stand age #180
  • Remove "with No inputs treatment" from plot names
  • deal with cases of plots erroneously counted as unmanaged: ForC_private issue #19
  • there are a large number of sites labeled "mature" in SRDB but with stand.age<100 (ranging down to 0), and "mature" is not used the same way in SRDB (see SRDB issue 28). Therefore, please change the code such that "Mature" is left out of the name.
  • there are four sites labeled "aggrading" in SRDB but with stand.age≥100. Please change the code such that "Aggrading" is left out of the name if stand.age≥100
  • there are a handful of plots with treatments ("management" in ForC terminology) that are labeled as "unmanaged". To avoid confusion, let's remove "unmanaged" from these plot names.
  • there are a handful of records where ForC.investigator is labeled 'NA' (should be Ben).
@ValentineHerr
Copy link
Member

ValentineHerr commented May 14, 2019

@teixeirak,

About

there are a handful of plots with treatments ("management" in ForC terminology) that are labeled as "unmanaged". To avoid confusion, let's remove "unmanaged" from these plot names.

Below is a table of all combinations of Ecosytem_stage and Manipulation that exist in SRDB (forest and savanna).
I am not sure they all make sense, (example: "Undrained, unplanted" is considered as managed). Also I am not sure "Natural' is always appropriate.
But for unmanaged, does that mean I should keep it only for plots that have "None" or "No inputs" in Ecosytem_stage ?

Also, so far in the code we had "put the manipulation and manipulation level in the plot.name if manipulation is not "None". But I guess it should be "... if manipulation is not "None" nor "No inputs", right ?
Never mind, this is YES.

  Burned Burned, cleared Burned, thinned Burned, understory thinned Burning Burning, thinning Burnt C. alata addition CaCl2 added CaHPO4 added Clear-cut Clear-cut, Humus and mineral soil mixed thoroughly to a depth of 30 cm Clearcut Clearcut no slash Clearcut with slash Clearcut, burning Clearcut, logging residue Clearcut, no residue Clearcut, slash burnt Clearcut, soil mixing CO2 CO2, fertilized CO2, heated CO2, irrigated CO2, O3 Deep soil frost Disk harrowing Double precipitation Drained Drained, planted Drought Drought, irrigation Fertilization Fertilized Fertilized, CO2 Fertilized, drained Fertilized, irrigated Fertilized, irrigation Fertilized, thinned Grazed Harvest Heated Heated (air, soil) Heated (soil) Heated, CO2 Heating Heating, CO2 Herbicide Herbicide, fertilization High soil N High soil N, CO2 Insecticide Irrigated Irrigated+fertilized Irrigation Irrigation, CO2 Irrigation, CO2, high N Irrigation, fertilized Irrigation, high N Logged Low soil N Low soil N, CO2 NaNO3 added Nitrogen Nitrogen, CO2 Nitrogen, phosphorous No inputs None O-horizon removed O3 Organic residues removed Partial cut Partial harvest Post-flush burn Post-flush cut Pre-flush burn Pre-flush cut Rainfall exclusion Salvage logging Scarified Selection cutting Shallow soil frost Soil compaction Soil warming Species added Species added; insecticide Stem wood harvest Thinned Thinned, burned Thinned, irrigation, fertilized Thinning Thinning, Stumps extrated from soil Throughfall exclusion Tilled Tilled, Grazed Trenching Understory harvesting Understory removal Understory removal, C. alata addition Understory removed Understory thinned Undrained, planted Undrained, unplanted Vegetation control Warmed Warming Warming, drought Weed control Weed control, irrigation Weed control, irrigation, fertilized Weed control, irrigation, fertilized, pest control Weeding, fertilization Woody adelgid infestation
Managed 1 0 0 0 3 0 0 1 0 0 2 2 19 2 2 0 3 4 2 1 44 6 4 1 0 0 1 0 16 2 6 2 7 140 2 7 4 0 2 1 21 4 2 2 0 0 0 2 1 2 2 1 2 1 18 4 2 15 2 0 2 2 0 2 2 0 0 750 4 0 4 1 1 0 0 0 0 0 2 0 1 0 0 1 0 1 4 33 0 1 5 2 0 1 1 0 1 3 1 0 0 2 2 8 6 1 0 1 1 1 1 2 0
Natural 7 0 3 3 1 5 1 0 3 3 0 0 13 0 0 2 0 0 0 0 8 0 4 0 0 1 0 1 0 0 22 0 1 59 0 0 0 0 0 0 0 16 0 0 1 2 2 0 0 0 0 0 0 0 15 0 0 0 0 0 0 0 3 1 0 1 4 1883 0 0 0 0 0 3 3 3 3 1 0 1 0 1 1 1 0 0 0 8 1 0 0 0 2 0 0 3 0 0 0 1 3 0 0 0 6 2 3 0 0 0 0 0 2
Unmanaged 2 1 0 0 0 0 0 0 0 0 0 0 3 0 0 0 0 0 2 0 25 0 0 0 9 0 0 2 1 0 2 0 8 8 1 0 0 1 0 0 8 0 0 0 0 0 0 0 0 0 0 0 0 0 10 0 0 0 0 1 0 0 0 0 0 0 5 436 0 9 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0

@ValentineHerr
Copy link
Member

note about

there are a large number of sites labeled "mature" in SRDB but with stand.age<100 (ranging down to 0), and "mature" is not used the same way in SRDB (see SRDB issue 28). Therefore, please change the code such that "Mature" is left out of the name.

Stand.age is coming from Age_disturbance and if that is missing we take Age_ecosystem. Maybe Age_disturbance is not relevant when it is a minor disturbance? That might be why there are so many young plots that are labeled as mature ?

@bpbond
Copy link
Contributor

bpbond commented May 14, 2019

Hmm, could be. In SRDB Age_disturbance should generally reset with any kind of disturbance.

I am not sure they all make sense, (example: "Undrained, unplanted" is considered as managed). Also I am not sure "Natural' is always appropriate.

There's some fuzziness around the edges, but in general the Natural-Unmanaged-Managed binning is useful I think: "no human influence", "no recent/active human management", "actively managed".

@teixeirak
Copy link
Member Author

I am not sure they all make sense, (example: "Undrained, unplanted" is considered as managed). Also I am not sure "Natural' is always appropriate.

There's some fuzziness around the edges, but in general the Natural-Unmanaged-Managed binning is useful I think: "no human influence", "no recent/active human management", "actively managed".

I think that in many cases, treatments that we count as management may have been applied to natural/ unmanaged stands. That is, the designations in SRDB apply prior to application of experimental treatments. Is this correct, @bpbond ?

@bpbond
Copy link
Contributor

bpbond commented May 14, 2019

the designations in SRDB apply prior to application of experimental treatments

Right!

@teixeirak
Copy link
Member Author

the designations in SRDB apply prior to application of experimental treatments

@ValentineHerr, this means that we should drop the managed/unmanaged/natural for all stands with treatments and the mature/aggrading designation when the disturbance is stand-clearing.

@ValentineHerr
Copy link
Member

@teixeirak,

I I am not sure I understand this....

Here is the current plot.name definition (coming from this issue)
"[Ecosystem_state] [stage] [Biome] [Leaf_habit (changing "mix" to "mixed"] [Ecosystem_type] , with [Manipulation, if any] ([level, if any]) treatment, "stand established around [year of measurement - stand.age] ([if any])"

(note: [stage] is Aggrading, Mature, Natural or NA)

@ValentineHerr, this means that we should drop the managed/unmanaged/natural for all stands with treatments and the mature/aggrading designation when the disturbance is stand-clearing

I think I translate this to:

  • If a record
    • has "None" or "No inputs" in Manipulation,
      OR
    • has any Manipulation corresponding to "stand-clearing" in the manipulations.csv AND is "natural" in stage

---> then keep [stage] from the plot.name definition.

  • If a record
    • has anything but "None" or "No inputs" in Manipulation, or "stand-clearing"

--> then drop [stage] from the plot.name definition.

Is that correct??

@teixeirak
Copy link
Member Author

Not quite. There are two separate changes.

1:

If a record
    has anything but "None" or "No inputs" in Manipulation, or "stand-clearing"

--> then drop [Ecosystem_state] from the plot.name definition.

@teixeirak
Copy link
Member Author

teixeirak commented May 17, 2019

2: If a record (has any Manipulation corresponding to "stand-clearing" in the manipulations.csv and [stage = mature] )OR if (age<100 years and [stage = mature] ),

---> then drop [stage] from the plot.name definition.

@ValentineHerr
Copy link
Member

Is this still valid ?

"there are four sites labeled "aggrading" in SRDB but with stand.age≥100. Please change the code such that "Aggrading" is left out of the name if stand.age≥100"

@teixeirak
Copy link
Member Author

These records have been fixed in SRDB.

@ValentineHerr
Copy link
Member

@teixeirak , about

there are a handful of records where ForC.investigator is labeled 'NA' (should be Ben).

see this issue

@ValentineHerr
Copy link
Member

there are a handful of plots with treatments ("management" in ForC terminology) that are labeled as "unmanaged". To avoid confusion, let's remove "unmanaged" from these plot names.

I believe this is fixed but @teixeirak can double check (might need to double check in ForC_simplified once I push everything)

@teixeirak
Copy link
Member Author

I actually see a few cases of plots with treatments where "unmanaged" or "natural" remains in the plot name. For example:

  • measurement.ID=22056: Unmanaged Aggrading Temperate Deciduous Forest with CO2 (534 ppm) treatment. Stand established around 1997
  • measurement.ID=22216: Natural Aggrading Tropical NA Forest with Fertilized treatment. Stand established around 1993.5

I don't think these are hugely problematic or confusing, so if its a pain to fix we can leave it.

@ValentineHerr
Copy link
Member

for the first example (SRDB record 1634), it is because it says "unmanaged" in SRDB Ecosystem_state
for the second example (SRDB record 1986) it is because it says "natural" in SRDB Ecosystem_state

I added some code to say
"... OR if Ecosystem_state is "Unmanaged" or "Natural" and manipulation is not c("None", "No inputs"), ... then do not put Ecosystem_state in the plot.name".

Hopefully that will fix the cases you found

@teixeirak
Copy link
Member Author

there are a large number of sites labeled "mature" in SRDB but with stand.age<100 (ranging down to 0), and "mature" is not used the same way in SRDB (see SRDB issue 28). Therefore, please change the code such that "Mature" is left out of the name.

@ValentineHerr, this doesn't seem to have been completely implemented. For example, citation.ID 28417 has plot name "Mature Subtropical Deciduous Forest. Stand established around 1993" and stand.age=19.

@ValentineHerr
Copy link
Member

Thanks for catching that Krista, I had not implemented that correctly. It is now fixed in the "with SRDB" branch.

@ValentineHerr
Copy link
Member

@teixeirak, the only cases where there is "Mature" in plot.name now is where age is >=100 or "NAC". Is that ok?

@teixeirak
Copy link
Member Author

Yes.

@teixeirak
Copy link
Member Author

You can go ahead and merge into the master now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants