Project

General

Profile

« Previous | Next » 

Revision 13434

validation/aggregating/plots/bien3_validations_salvias_vegbien.sql: updated to DB

View differences:

trunk/validation/aggregating/plots/bien3_validations_salvias_vegbien.sql
337 337
  GROUP BY project.projectname, plot.authorlocationcode
338 338
  ORDER BY project.projectname, plot.authorlocationcode;
339 339

  
340
-- _plots_20_tnrs_input_names
341
 SELECT DISTINCT taxonlabel.taxonomicname AS tnrs_input_name
342
   FROM taxonlabel
343
  WHERE ((taxonlabel.source_id = ( SELECT source_by_shortname(:datasource::text) AS source_by_shortname)) AND (taxonlabel.taxonomicname IS NOT NULL));
340
-- _plots_20_tnrs_names
341
 SELECT taxonlabel.taxonomicname AS verbatim_name_with_author, 
342
    taxonlabel.taxonomicname AS tnrs_input_name, 
343
    taxon_scrub.scrubbed_unique_taxon_name AS tnrs_output_name, 
344
    taxon_scrub."morphospeciesSuffix" AS morphospecies_suffix
345
   FROM ((taxonverbatim
346
   JOIN taxonlabel USING (taxonlabel_id))
347
   JOIN "TNRS".taxon_scrub ON ((taxon_scrub."concatenatedScientificName" = taxonlabel.taxonomicname)))
348
  WHERE (taxonverbatim.source_id = ( SELECT source_by_shortname(:datasource::text) AS source_by_shortname))
349
  ORDER BY taxonlabel.taxonomicname;
344 350
/*
345 351
The first check is done while checking up on Aaron''s quantitative validations
346 352
("comparing the results of the plot output queries run on VegBIEN to the data in
......
349 355
the verbatim name and not the resolved name, this first check is important. If
350 356
Aaron is messing up the verbatim name somehow, the resolved name will not be
351 357
correct.
352
*/
353 358

  
354
-- _plots_21_tnrs_output_names
355
 SELECT DISTINCT taxon_scrub.scrubbed_unique_taxon_name AS tnrs_output_name
356
   FROM (taxonlabel
357
   JOIN "TNRS".taxon_scrub ON ((taxon_scrub."concatenatedScientificName" = taxonlabel.taxonomicname)))
358
  WHERE ((taxonlabel.source_id = ( SELECT source_by_shortname(:datasource::text) AS source_by_shortname)) AND (taxon_scrub."concatenatedScientificName" IS NOT NULL));
359
/*
360 359
The second check should focus on determining if Aaron is reconstructing
361 360
morphospecies names correctly. The TNRS stores the morphospecies part of the
362 361
name (e.g., "sp.1") in the column "Unmatched_terms"; a bit of additional

Also available in: Unified diff