Coder Social home page Coder Social logo

chicago / clear-water-app Goto Github PK

View Code? Open in Web Editor NEW
7.0 5.0 4.0 4.62 MB

Generate water quality predictions for Chicago beaches, and upload to https://data.cityofchicago.org/Parks-Recreation/Beach-E-coli-Predictions/xvsz-3xcj

R 99.49% Shell 0.51%

clear-water-app's Introduction

Clear Water App

This is a companion repository to the Clear Water model repo for predicting beach water quality. It can be used as a production-ready solution to deliver model predictions to a Socrata data portal and map.

Notes

The file model.Rds is obtained by running Master.R in the Clear Water model repo. To generate the file, set the productionMode variable in the model repo to TRUE. Place the file in the data directory of this repo.

Make sure you also set the datasetUrl variable in app.R.

Socrata Credentials

To upload predictions to a Socrata portal, this application uses Chicago's RSocrata R package. You will have to authenticate with your data portal creditionals in order to add data to a predictions dataset. To authenticate with Socrata and upload predictions using this automated app, create files to save login and app token details in the credentials folder, named as follows:

  • email.txt
  • password.txt
  • token.txt

App.R will read these credentials and use them to send the data to the Socrata dataset.

Model Settings

This app is currently configured to predict water quality at beaches within a regional system. Specifically, it predicts the quality of some beaches along Chicago's Lake Michigan coastline based on the same-day bacteria observed at 5 predictor beaches.

Contributing

If you are interested in contributing to this project, see our Contribution Guide.

clear-water-app's People

Contributors

nicklucius avatar tomschenkjr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

clear-water-app's Issues

Not enough DNA test results to issue a prediction at "today"

Dear Tom Schenk Jr,
I'm sorry if I'm asking something obvious but I'm a freshman in programming and I'm encountering 2 different problems in Running the app.R code (Run with sys.time=2017-11-18 12:43:00"):

  1. The datasetUrl value "https://data.cityofchicago.org/Parks-Recreation/Beach-Lab-Data/2ivx-z93u/data" gives the error 403, so I changed this value to "https://data.cityofchicago.org/api/views/2ivx-z93u/rows.csv?accessType=DOWNLOAD" and then I'm able to assign the datatable to labPortal. Have I done the right thing?

  2. Then I tried to generate predictions but the variable readyToModel is FALSE and so I'm not able to perform the predictions. So I tried to change the today value to an old date (such as may 2017) but readyToModel is still FALSE.

What I can do to solve these issues?
Thank you

Giada

Randomize website

We should see if it is possible to randomize which website is seen by end-users. This sort of randomization can then be used to estimate which visualizations and webpages are most effective.

Missing `credentials` folder

The instructions ask users to place credentials such as email.txt, password.txt, and token.txt in the credentials/ folder. However that folder isn't placed in the repo because, presumably, it is empty because the aforementioned text files are in .gitignore. This may a bit confusing for users.

Git does not display empty folders, but there is an emerging practice to place a .gitkeep file as a placeholder file so the folder will display.

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.