Skip to content

mdsung/20221021_workshop

Repository files navigation

Reproducible Research

  • Author: MinDong Sung
  • Date: 2022-10-21
  • For: DHLab

VSCode for Data Science

  • Remote SSH
    • Ctrl + R: 최근 workspace 목록 확인
    • [참고] 비밀번호 입력하기 힘들면 SSH key 생성하기
  • Shortcut
    • F5: Run
    • Ctrl or CMD + F5: Run without debugging
    • Ctrl or CMD + D: multi cursor
    • Ctrl or CMD + Shift + P: palette
  • Duplicate workspace
  • Jupyter notebook in VScode
    • #%%
    • Shift + Enter로 jupyter notebook 실행 : (setting.json)
      "jupyter.sendSelectionToInteractiveWindow": true
      
  • Path set
    • Python script
      #.env
      PYTHONPATH=.
      
      # setting.json
      "python.envFile": "${workspaceFolder}/.env"
      
    • Python notebook
      # setting.json
      "jupyter.notebookFileRoot": "${workspaceFolder}"
      

Project Management

  • envioronment 관리

    • pyenv: python version 관리
    • poetry: python library 관리
      • poetry init -n
      • poetry add
      • poetry install
    • using R in vscode - VSCode-R
    • renv: R library 관리
    • library(here)
  • project structure

    • data/
      • raw/
      • processed/
    • src/
    • figure/
    • README.md
    • Snakefile/Makefile: for workflow
  • git - code backup and version control

    • git init
    • git add
    • git commit
    • git push

  • DVC - Data backup and version control
    • AWS-cli prerequisite
    • poetry add 'dvc[s3]'
    • dvc init
    • dvc remote add -d data s3://data-folder
    • dvc remote modify --local data access_key_id '[mykey]'
    • dvc remote modify --local bikes secret_access_key '[mysecret]'
    • dvc add
    • dvc push
    • dvc commit
    • dvc pull

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors