Skip to content

Instantly share code, notes, and snippets.

View chilampoon's full-sized avatar
👽
need more epochs

poonchilam chilampoon

👽
need more epochs
  • Lenapehoking
View GitHub Profile
@chilampoon
chilampoon / fix_t2t_gff.py
Created December 8, 2022 04:51
Fix the T2T gff3 file to prevent errors when getting a gffutils db
#!/usr/bin/env python
# fix t2t gff3 error
# now the problem is ids for some start&stop condons/exons are not unique
# 11/20/2022
import sys,gzip
from collections import defaultdict
def sep_info(info):
@chilampoon
chilampoon / rpy2_in_jupyter.txt
Last active July 3, 2022 15:46
Convert dataframes of R & Python using rpy2 in jupyter
# ------ a python cell ------
%load_ext rpy2.ipython
pd_df = pd_df.T
# ------ an R cell ------
%%R -i pd_df
# `-i pd_df` means access to the global variable pd_df
r_df = do.something(pd_df)
@chilampoon
chilampoon / http_load_balancer_setup_gcp.sh
Created July 14, 2021 20:51
Set up an HTTP load balancer with a managed instance group of 2 nginx web servers on Google Cloud Platform (Qwiklab)
# setup
gcloud auth list
gcloud config set compute/zone us-east1-b
gcloud config set compute/region us-east1
# create an instance template
cat << EOF > startup.sh
#! /bin/bash
apt-get update
apt-get install -y nginx
@chilampoon
chilampoon / HMM.ipynb
Created May 1, 2021 21:22
2-state Hidden Markov Model
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@chilampoon
chilampoon / GSoC_Final_Report.md
Last active August 3, 2021 15:30
GSoC 2020 Final Report

GSoC 2020 Final Report

This Gist summarizes my work for the Reactome project "Query Reactome Data in R" during the Google Summer of Code 2020.

I would first like to begin by thanking my mentors Justin Cook, Joel Weiser, and Solomon Shorser for their guidance and support this summer. It was a privilege to learn from such a talented and experienced team.

Main objective

The main objective was to create an interface in R to query data from the Reactome knowledgebase.

@chilampoon
chilampoon / s3.download.md
Last active June 1, 2021 17:15
Download AWS s3 bucket objects

Download AWS s3 bucket objects

  • Install AWS CLI
pip3 install awscli --upgrade --user
# export PATH=~/.local/bin:$PATH (add into ~/.bashrc)
# source ~/.bashrc
  • Configure the CLI
@chilampoon
chilampoon / updateR.md
Last active August 19, 2022 19:36
Update R, R studio server and R packages

Upgrade RStudio Server (Version:1.1.463 Released:2018-10-29) in Ubuntu

sudo /usr/sbin/rstudio-server stop #stop the current version
# Download
sudo apt-get install gdebi-core
wget https://download2.rstudio.org/rstudio-server-1.1.463-amd64.deb
sudo gdebi rstudio-server-1.1.463-amd64.deb