Coder Social home page Coder Social logo

m-d-grunnill / ai4ph-r Goto Github PK

View Code? Open in Web Editor NEW

This project forked from juanliohri/ai4ph-r

0.0 0.0 0.0 3.31 MB

Demo and assignment materials for the AI4PH course: Developing and Deploying Transparent and Reproducible Algorithms for Public Health

R 100.00%

ai4ph-r's Introduction

AI4PH-R

Demo and assignment materials for the AI4PH course: Developing and Deploying Transparent and Reproducible Algorithms for Public Health.

Included files in this repository:

R markdown (.Rmd) files and R script (.R) files:

  1. AI4PH_example.Rmd: The demo code that will be reviewed in class, which includes building and evaluating a logistic regression (lr) model on a stroke dataset using tidymodels, and calling the plumber script to generate an API. The students are recommended to run through this file themselves to make sure that their R environment is set-up correctly, all required packages have been installed successfully, and get familiar with the data, tidymodels, and plumber.
  • Read in: train_data.rds (included, the harmonized train data set)
  • Produce: stroke_lr_workflow.rds (not included, the trained workflow object including recipes and fitted lr model)
  1. AI4PH_assignment.Rmd: The assignment file. In this assignment, the student will validate the stroke model we developed in class (AI4PH_example.Rmd) using a different dataset: valid_data.rds. You will run into issues using this dataset as it is because this is a raw dataset without data harmonization, which means that some variables in this dataset are different from the harmonized dataset we used to train and evaluate the model. Your job here is to harmonize the validation data so that it's in the same format as the example data we used in class (see line 79-83 in this file). You can refer to train_data_variables.csv to see the format in the harmonized train data.
  • Read in:
    • valid_data.rds (included, the unharmonized validation set)
    • stroke_lr_workflow.rds (not included, this is generated by runing AI4PH_example.Rmd)
  • Reference: train_data_variables.csv (metadata of the train set)
  • Produce: harmonized_valid_data.rds (the harmonized validation set)
  1. stroke_lr_plumber.R: The plumber script, which will be used in both in class demo and assignment, no modification needed.
  • Read in: stroke_lr_workflow.rds (not included, this is generated by runing AI4PH_example.Rmd)

Data files: Please place the data files and the R markdown files in the same folder.

  1. train_data.rds: the harmonized train data set, used in AI4PH_example.Rmd to train the model.
  2. valid_data.rds: the un-harmonized validation data set, used in AI4PH_assignment.Rmd.

Metadata/ data dictionary:

  1. train_data_variables.csv (data dictionary of the train set). You’ll also use this to help you harmonize the validation data in the assignment.

Assignment submission and office hour

To submit your work on the assignment, please send us the assignment file with your code and all the output, you can find our emails on Canvas. Please rename the file as AI4PH_assignment_YourName.Rmd. E.g. my name is Juan Li and I will rename my submission as AI4PH_assignment_JuanLi.Rmd.

If you have any question, you are encouraged to join the office hour on Feburary 19th.

ai4ph-r's People

Contributors

juanliohri avatar

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.