Skip to content

Instantly share code, notes, and snippets.

View tyasird's full-sized avatar
:electron:

Yasir Demirtaş tyasird

:electron:
View GitHub Profile
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@decodebiology
decodebiology / normalize_read_counts.R
Created October 24, 2020 20:21
RNA-seq read count normalization (TPM and RPKM)
#Rscript normalize_featurecounts.R counts_table.txt tpm ;
#Rscript normalize_featurecounts.R counts_table.txt rpkm ;
#Sample table###
#GeneID<TAB>sample1<TAB>sample2<TAB>sample3<TAB>Length
#Gene1<TAB>10<TAB>4<TAB>5<TAB>1500
#Gene2<TAB>20<TAB>43<TAB>60<TAB>4300
@dsalaj
dsalaj / juwels_cheatsheet.md
Last active February 5, 2024 11:25
JUWELS cheatsheet

local .ssh/config contents

Host juwels
    HostName juwels.fz-juelich.de
    User salaj1
    IdentityFile ~/.ssh/id_rsa_juwels.pub

To connect simply ssh juwels.

juwels

@scf37
scf37 / simulate_scanned_PDF.md
Created April 11, 2018 11:49
Simulate a scanned PDF with ImageMagick

Simulate a scanned PDF with ImageMagick

  1. Download and install Ghostscript and ImageMagick + Convert Module
  2. Execute the following command in the console (change the filename)
$ convert -density 200 INPUT.pdf -rotate 0.3 +noise Multiplicative -format pdf  -quality 85 -compress JPEG -colorspace gray OUTPUT.pdf

Description of the options

  • -density: set the input DPI to 200
  • -rotate: set Page rotation to 0.3 degrees
@cplaisier
cplaisier / geoParseExample.py
Created March 27, 2018 03:27
Example of use GEOParse
import GEOparse
import pandas as pd
import matplotlib.pyplot as plt
import numpy
from matplotlib.backends.backend_pdf import PdfPages
#gseNums = ['GSE14860']
#gseNums = ['GSE49278', 'GSE19750', 'GSE10846']
gseNums = ['GSE19417', 'GSE49278', 'GSE19750', 'GSE10846', 'GSE39582', 'GSE35158', 'GSE19422', 'GSE19987', 'GSE32894', 'GSE35158', 'GSE27155', 'GSE33630', 'GSE56303', 'GSE29695', 'GSE10141', 'GSE9843', 'GSE25097', 'GSE32225', 'GSE26566', 'GSE65858', 'GSE39366', 'GSE22138', 'GSE46517', 'GSE71729', 'GSE8607', 'GSE4573', 'GSE29354', 'GSE71118', 'GSE19949', 'GSE15641', 'GSE26253', 'GSE15460', 'GSE21034', 'GSE9891', 'GSE32062', 'GSE72094', 'GSE26939', 'GSE29174', 'GSE31448', 'GSE45725', 'GSE40435', 'GSE14860']
@SimonLarsen
SimonLarsen / parse_geo_series_matrix.r
Last active January 18, 2022 12:25
R script for reading GEO series matrix file, parsing characteristics and mapping probes to gene IDs
library(data.table)
library(foreach)
args <- commandArgs(TRUE)
#### Input files ####
# Series Matrix File
SERIES_FILE <- args[1]
# Platform data table obtained from GEO.
PLATFORM_FILE <- args[2]
@ThomasG77
ThomasG77 / countries.geojson
Last active January 4, 2024 19:54
Sample Leaflet with GeoJSON
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@fbrundu
fbrundu / hyper.md
Last active December 19, 2023 14:37
Calculate hypergeometric probability with Python SciPy

A poker hand consists of 5 cards dealt at random without replacement from a standard deck of 52 cards of which 26 are red and the rest black. A poker hand is dealt. Find the chance that the hand contains three red cards and two black cards.

To achieve it, we use the [hypergeometric][1] probability mass function. We want 3 cards from the set of 26 red cards and 2 from the set of 26. So the parameters for the hypergeometric function are:

M = 52  # Total number of cards
n = 26  # Number of Type I cards (e.g. red cards) 
N = 5   # Number of draws (5 cards dealt in one poker hand)
k = 3   # Number of Type I cards we want in one hand