Skip to content

Commit

Permalink
change name of missing history record error #176
Browse files Browse the repository at this point in the history
  • Loading branch information
ValentineHerr committed Aug 26, 2021
1 parent 2c1db5e commit 801ea01
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions scripts/QA_QC/checks.R
Original file line number Diff line number Diff line change
Expand Up @@ -68,17 +68,17 @@ cat(paste("there are", sum(duplicated(MEASUREMENTS$measurement.ID)), "measuremen
# View(MEASUREMENTS[MEASUREMENTS$measurement.ID %in% MEASUREMENTS$measurement.ID[duplicated(MEASUREMENTS$measurement.ID)],])


# For each site-plot combination in MEASUREMENTS, there is a corresponding site-plot record in PLOTS
# For each site-plot combination in MEASUREMENTS, there is a corresponding site-plot record in HISTORY
MEASUREMENTS %>%
anti_join(PLOTS, by = c("sites.sitename", "plot.name")) %>%
anti_join(HISTORY, by = c("sites.sitename", "plot.name")) %>%
distinct(measurement.ID, sites.sitename, plot.name) ->
m_no_p
m_no_h

look_name <- "m_no_p"
look_name <- "m_no_h"
look <- get(look_name)
say <- paste("There are", nrow(look), "measurements with no corresponding plot record\n")
say <- paste("There are", nrow(look), "measurements with no corresponding history record\n")
cat(say)
filename <- "error_reports/meas_with_no_plot_record.csv"
filename <- "error_reports/meas_with_no_history_record.csv"

if(nrow(look) > 0) {
err <- c(err, say)
Expand Down

0 comments on commit 801ea01

Please sign in to comment.