ncss-tech / ISSR-800

Intermediate Scale Soil Raster (data) prepared on an 800m grid.
https://casoilresource.lawr.ucdavis.edu/soil-properties/
8 stars 0 forks source link

soil moisture regime #9

Open dylanbeaudette opened 6 years ago

dylanbeaudette commented 3 months ago

See holes in grid for ideas on what might be going on. In many cases the source data in the cotaxmoistcl table is missing.

Think about extracting SMR from family-level taxa as backup plan.

library(soilDB)
library(SoilTaxonomy)

.sql <- "
SELECT mukey, co.cokey, compname, comppct_r, taxclname, taxmoistcl AS smr
FROM component AS co LEFT JOIN cotaxmoistcl AS ctxm ON co.cokey = ctxm.cokey
WHERE mukey = '463319' 
ORDER BY comppct_r DESC;
"

x <- SDA_query(.sql)

x$ex_smr <- sapply(x$taxclname, function(i) {
  unname(extractSMR(i))
})

x