Skip to content

Instantly share code, notes, and snippets.

View yellowbridge's full-sized avatar
🎯
Focusing

yellowbridge

🎯
Focusing
View GitHub Profile
@sinarueeger
sinarueeger / extract-genetic-data.md
Last active March 13, 2024 14:21
Extract data for single SNPs from large genetic datasets
@dcomtois
dcomtois / userDefineLang.xml
Created December 23, 2016 04:02
Notepad++ style configuration for SAS
<NotepadPlus>
<UserLang name="sas" ext="sas" udlVersion="2.1">
<Settings>
<Global caseIgnored="yes" allowFoldOfComments="no" foldCompact="no" forcePureLC="0" decimalSeparator="0" />
<Prefix Keywords1="no" Keywords2="no" Keywords3="no" Keywords4="yes" Keywords5="no" Keywords6="no" Keywords7="no" Keywords8="no" />
</Settings>
<KeywordLists>
<Keywords name="Comments">00* 00; 01 02; 03/* 04*/</Keywords>
<Keywords name="Numbers, prefix1"></Keywords>
<Keywords name="Numbers, prefix2"></Keywords>
@joosti
joosti / wrds_fetch_macro.sas
Last active September 24, 2022 09:22
Downloading multiple datasets from SAS
/*
fetch: fetches a dataset from WRDS and creates simple indices
dependency: this macro uses Clay macro %DO_OVER
remLib: remote library directory (e.g. /wrds/crsp/sasdata/a_stock )
locLib: local library name (e.g. work)
dset: dataset to download (e.g. dsenames)
indices (optional): variable names on dset to create index on after download (e.g. permno)
*/
@benrasmusen
benrasmusen / statistics-distributions.js
Created October 4, 2011 15:44
JavaScript library for calculating critical values and upper probabilities of common statistical distributions
/*
* NAME
*
* statistics-distributions.js - JavaScript library for calculating
* critical values and upper probabilities of common statistical
* distributions
*
* SYNOPSIS
*
*
@mrdwab
mrdwab / Stratified.R
Created May 21, 2011 17:06
R stratified random sampling from a data frame
stratified = function(df, group, size) {
# USE: * Specify your data frame and grouping variable (as column
# number) as the first two arguments.
# * Decide on your sample size. For a sample proportional to the
# population, enter "size" as a decimal. For an equal number
# of samples from each group, enter "size" as a whole number.
#
# Example 1: Sample 10% of each group from a data frame named "z",
# where the grouping variable is the fourth variable, use:
#