Skip to content

nbcnews/DE-Coding-Challenge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NBC DE Coding Challenge

Data Engineering Coding Challenge

Instructions

You will be working on following coding challenges

Challenge-1 : Refactor existing code following the best practices and coding conventions

Challenge-2 : Read bitcoin api and structure the api in a given schema format

Challenge-1:

  • Refactor csv_parser.py
  • Justify your changes

Challenge-2:

Note: Feel free to change method signatures and constant/variable values.

  • Transform API data into following JSON schema

    ` Output schema:
      {
          "date": "{date}",
          "price": "{value}",
          "direction": "{up/down/same}",
          "change": "{amount}",
          "dayOfWeek": "{name}”,
          "highSinceStart": "{true/false}”,
          "lowSinceStart": "{true/false}”
      }`
    
    • one entry per day at "00:00:00" hours

    • results ordered by oldest date first.

    • "date" in format "2019-03-17T00:00:00"

    • "price" in 2 decimal dollars

    • "direction" is direction of price change since previous day in the list, first day can be "na" ({up/down/same})

    • "change" is the price difference between current and previous day. "na" for first

    • "dayOfWeek" is name of the day (Saturday, Tuesday, etc)

    • "highSinceStart" true/false if highest since list start. "na" for first

  • Return Transformed JSON.

  • Call required methods in the handler code
  • Check output matches and returns the expected value

Note: Please feel free to use Jupyter notebook for both challenges, repository contains a notebook file in case needed.

About

Data Engineering Coding Challenge

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •