Coder Social home page Coder Social logo

wqg_data's People

Contributors

atillmanns avatar heathergranger avatar joethorley avatar repo-mountie[bot] avatar sebdalgarno avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

wqg_data's Issues

The following enteries need Days and Samples

# A tibble: 12 x 5
   Variable                                  EMS_Code Use                         Days Samples
   <chr>                                     <chr>    <chr>                      <dbl>   <dbl>
 1 Cyanobacteria Total                       NA       Recreation - Swimming         NA      NA
 2 Cyanobacterial Toxins: Microcystins Total EMS_MCYS Recreation - Swimming         NA      NA
 3 Temperature                               EMS_0013 Drinking Water - Aesthetic    NA      NA
 4 Temperature                               EMS_TEMF Drinking Water - Aesthetic    NA      NA
 5 Temperature                               EMS_0013 Recreation - Swimming         NA      NA
 6 Temperature                               EMS_TEMF Recreation - Swimming         NA      NA
 7 Turbidity                                 EMS_0015 Drinking Water                NA      NA
 8 Turbidity                                 EMS_TURF Drinking Water                NA      NA
 9 Turbidity                                 EMS_0015 Drinking Water                NA      NA
10 Turbidity                                 EMS_TURF Drinking Water                NA      NA
11 Turbidity                                 EMS_0015 Drinking Water                NA      NA
12 Turbidity                                 EMS_TURF Drinking Water                NA      NA

Commit not merged?

@joethorley - I pushed the wqgs_all.csv file with the added EMS codes but there is something about merging with main branch? Is there something else I have to do to merge in the changes? Thanks!

Error in limit for Hexachlorobenzene in marine aquatic life?

Consider the 5th row - the coded limit is 0.0231 ug/g but the notes say 0.23 ug/g - can you confirm which is correct @HeatherGranger

           Variable EMS_Code                       Use   Limit Units
1 Hexachlorobenzene EMS_H003   Agriculture - Livestock    0.52  ug/L
2 Hexachlorobenzene EMS_H003 Aquatic Life - Freshwater   0.011  ug/g
3 Hexachlorobenzene EMS_H003 Aquatic Life - Freshwater   0.241  ug/g
4 Hexachlorobenzene EMS_H003     Aquatic Life - Marine 0.00381  ug/g
5 Hexachlorobenzene EMS_H003     Aquatic Life - Marine  0.0231  ug/g
                                                                            Notes
1                                                                            <NA>
2                                      based on equalibrium partitioning approach
3                                                                            <NA>
4                                                                            <NA>
5 0.23g/g maximum level for dredge disposal based on apparent effects threshold

The following variables are currently coded as the mean of 1 sample in 1 day

# A tibble: 46 x 3
   Variable                                EMS_Code Use                     
   <chr>                                   <chr>    <chr>                   
 1 Chloride Dissolved                      EMS_1104 Drinking Water - Aesthe2 Chlorophenol, 2,3,4,6-TTCP              EMS_T037 Drinking Water - Aesthe3 Chlorophenol, 2,4-DCP                   EMS_D050 Drinking Water - Aesthe4 Chlorophenol, 2,4,6-TCP                 EMS_T042 Drinking Water - Aesthe5 Chlorophenol, DCP Total                 EMS_D060 Drinking Water - Aesthe6 Chlorophenol, DCP Total                 EMS_D060 Recreation - Swimming   
 7 Chlorophenol, MCP                       EMS_M050 Drinking Water - Aesthe8 Chlorophenol, MCP                       EMS_M050 Recreation - Swimming   
 9 Chlorophenol, PCP                       EMS_P022 Drinking Water - Aesthe10 Chlorophenol, PCP                       EMS_P022 Recreation - Swimming   
11 Chlorophenol, TCP Total                 EMS_T021 Drinking Water - Aesthe12 Chlorophenol, TCP Total                 EMS_T021 Recreation - Swimming   
13 Chlorophenol, TTCP Total                EMS_T020 Drinking Water - Aesthe14 Chlorophenol, TTCP Total                EMS_T020 Recreation - Swimming   
15 Chlorophyll a                           EMS_0143 Recreation - Swimming   
16 Copper Total                            EMS_CU-T Drinking Water - Aesthe17 Cyanobacteria Total                     NA       Recreation - Swimming   
18 Cyanobacterial toxins: Microcystins ToNA       Recreation - Swimming   
19 Ethylbenzene                            EMS_B021 Drinking Water - Aesthe20 Iron Total                              EMS_FE-T Drinking Water - Aesthe21 Manganese Total                         EMS_MN-T Drinking Water - Aesthe22 Methyl tertiary-butyl ether Total       EMS_MTBE Drinking Water - Aesthe23 Nitrate Total                           EMS_0110 Recreation - Swimming   
24 Nitrate Total                           EMS_0110 Recreation - Swimming   
25 Nitrate Total                           EMS_1110 Recreation - Swimming   
26 Nitrate Total                           EMS_1110 Recreation - Swimming   
27 Nitrite Total                           EMS_0111 Recreation - Swimming   
28 Nitrite Total                           EMS_0111 Recreation - Swimming   
29 Nitrite Total                           EMS_1111 Recreation - Swimming   
30 Nitrite Total                           EMS_1111 Recreation - Swimming   
31 Phosphorus Total                        EMS_P--T Drinking Water - Aesthe32 Phosphorus Total                        EMS_P--T Recreation - Swimming   
33 Sulphate Total                          EMS_0121 Drinking Water - Aesthe34 Temperature                             EMS_0013 Drinking Water - Aesthe35 Temperature                             EMS_0013 Recreation - Swimming   
36 Temperature                             EMS_TEMF Drinking Water - Aesthe37 Temperature                             EMS_TEMF Recreation - Swimming   
38 Toluene Total                           EMS_T001 Drinking Water - Aesthe39 Turbidity                               EMS_0015 Drinking Water          
40 Turbidity                               EMS_0015 Drinking Water          
41 Turbidity                               EMS_0015 Drinking Water          
42 Turbidity                               EMS_TURF Drinking Water          
43 Turbidity                               EMS_TURF Drinking Water          
44 Turbidity                               EMS_TURF Drinking Water          
45 Xylenes Total                           EMS_X006 Drinking Water - Aesthe46 Zinc Total                              EMS_ZN-T Drinking Water - Aesthe

@HeatherGranger Can you confirm that the following variables are based on the mean of 1 sample in 1 day (it seems wrong)

Chlorophenol, PCP - Drinking Water duplicate

in current all_wqgs data, all columns are identical for Chlorophenol, PCP - Drinking Water except Limit.

In original spreadsheet, the differ in Type (Aesthetic and Maximum) - somehow both now have type of Aesthetic Objective

Row with Limit = 0.06 should have Type 'Maximum'

Cases with open-ended Conditions

These need to be added to limits spreadsheet

From @atillmanns review of app:

"The second glitch is for substances with logical conditions and it can be traced back to the "all_wqgs.csv" sheet.  It seems we are missing maximum values for some of the parameters.  For example, for Alkalinity, when calcium dissolved is >8 mg/L then no guideline shows up.  However, the user needs to know that for water bodies with dissolved calcium >8 mg/L, the guideline is actually >20 mg/L.  This doesn't fit so well into our table structure.  I'll pull all the data together and then we can see how best to integrate this with the "all_wqgs.csv" spreadsheet."

Variables without EMS codes

# A tibble: 19 x 2
   Variable                              EMS_Code
   <chr>                                 <chr>   
 1 Cyanobacteria Total                   NA      
 2 3-hydroxyphenol                       NA      
 3 4-hydroxyphenol                       NA      
 4 Acrolein                              NA      
 5 Alcohol ethoxylated sulphate (AES)    NA      
 6 Alcohol ethoxylated surfactants (AE)  NA      
 7 Aniline Total                         NA      
 8 Diisopropanolamine                    NA      
 9 Lead - Tetra-ethyl lead               NA      
10 Lead - Tetra-methyl lead              NA      
11 Linear alkylbenzene sulphonates (LAS) NA      
12 Polychlorinated Biphenyl 105 Total    NA      
13 Polychlorinated Biphenyl 126 Total    NA      
14 Polychlorinated Biphenyl 169 Total    NA      
15 Polychlorinated Biphenyl 77 Total     NA      
16 Tebuthiuron                           NA      
17 Tin, Tricyclohexyltin                 NA      
18 Tin, Triethyltin                      NA      
19 Tin, Triphenyltin                     NA   

Guideline type needs to be added back in please

I see the column that described the guideline type (short, long, max, etc.) has been removed. This will be necessary for the user interface as it helps people interpret the guidelines and is used in all of our online documents.

Redefine acid sensitivity condition algebraically

Waterbody is highly sensitive to acid inputs (<4 mg/L dissolved calcium).  Sensitivity to acid inputs can be determined by the concentration of dissolved calcium: < 4 mg/L is highly sensitive to acid inputs; 4 to 8 mg/L is moderately sensitive; and > 8 mg/L is low sensitivity.

Can we redefine these algebraically in terms of EMS_CA-D?

ie EMS_CA-D < 4 etc

Diethyl phthalate duplicate

Two rows of Diethyl phthalate with all columns identical except for Limit
This confirmed in the raw spreadsheet originally sent by @atillmanns so is not a result of subsequent changes.
Which Limit is correct?

Ammonia Total - Long Term Chronic duplicates

There are two sets of duplicates for Ammonia Total - Long Term Chronic

  1. Condition = '0<= EMS_0013 & EMS_0013 < 15 & 6.5 <= EMS_0004 & EMS_0004 < 7.7'
  2. Condition = '0<= EMS_0013 & EMS_0013 < 15 & 7.7 <= EMS_0004 & EMS_0004 < 8'

Everything including Condition is identical but two possible Limits

This is confirmed in the original spreadsheet, so is not a result of subsequent changes

Variables with unrecognized EMS Codes

I think the following have been mangled by Excel - can we fix by just adding leading 0s so they are 4 characters in length (after the EMS_)?

# A tibble: 18 x 2
   Variable                                    EMS_Code
   <chr>                                       <chr>   
 1 Coliforms Fecal                             EMS_450 
 2 Colour Apparent                             EMS_1   
 3 Colour True                                 EMS_2   
 4 Cyanide Weak Acid Dissociable               EMS_157 
 5 Cyanobacterial Toxins: MicrocystinLR        EMS_MCYS
 6 Cyanobacterial Toxins: Microcystins Total   EMS_MCYS
 7 Enterococci                                 EMS_148 
 8 Escherichia coli                            EMS_147 
 9 Ethylbenzene                                EMS_B023
10 Ethylbenzene                                EMS_B024
11 Organic Carbon Total                        EMS_103 
12 Phenols Total                               EMS_117 
13 Resin acids Total                           EMS_128 
14 Salinity                                    EMS_130 
15 Sulfolane                                   EMS_SULF
16 Sulphate Total                              EMS_121 
17 Sulphide Total                              EMS_125 
18 Total dissolved solids (filterable residue) EMS_7 

Condition logic

There are many Conditions that look like this:
EMS_0107 | EMS_1107 > 10

I assume in R expression this should look like:
EMS_0107 > 10 | EMS_1107 > 10

If we look at 'Fluoride Total' - 'Freshwater Life - Aquatic', there are two possible guidelines depending on Conditions:

EMS_0107 > 10 | EMS_1107 > 10
EMS_0107 <= 10 | EMS_1107 <= 10

if EMS_0107 is 9 and EMS_1107 is 12, then both conditions evaluate to being TRUE and two guidelines will be shown.

is this the desired behaviour?

Type vs. Days/Samples

This relates to: https://github.com/poissonconsulting/shinywqg/issues/22

We need to organize Type vs. Days/Samples better. Here are all the unique combinations of these so far:

Screen Shot 2020-03-03 at 2 06 21 PM

See for example cases where Long term chronic have Days/Samples of 1 - this seems wrong.
Also cases where Type is Primary Contact but can have different Days/Samples.

I think we need to create a new column that defines the Time (Short term vs. long term) and a column that defines the Type - I feel that the current Type column is mixing these things,

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.