Skip to content

Instantly share code, notes, and snippets.

@CristinaSolana
CristinaSolana / gist:1885435
Created February 22, 2012 14:56
Keeping a fork up to date

1. Clone your fork:

git clone git@github.com:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
@yihui
yihui / README.md
Last active June 30, 2021 18:01
Preview all syntax highlighting themes in knitr (HTML and LaTeX)
@mblondel
mblondel / letor_metrics.py
Last active April 24, 2024 19:43
Learning to rank metrics.
# (C) Mathieu Blondel, November 2013
# License: BSD 3 clause
import numpy as np
def ranking_precision_score(y_true, y_score, k=10):
"""Precision at rank k
Parameters
@Chaser324
Chaser324 / GitHub-Forking.md
Last active May 13, 2024 11:18
GitHub Standard Fork & Pull Request Workflow

Whether you're trying to give back to the open source community or collaborating on your own projects, knowing how to properly fork and generate pull requests is essential. Unfortunately, it's quite easy to make mistakes or not know what you should do when you're initially learning the process. I know that I certainly had considerable initial trouble with it, and I found a lot of the information on GitHub and around the internet to be rather piecemeal and incomplete - part of the process described here, another there, common hangups in a different place, and so on.

In an attempt to coallate this information for myself and others, this short tutorial is what I've found to be fairly standard procedure for creating a fork, doing your work, issuing a pull request, and merging that pull request back into the original project.

Creating a Fork

Just head over to the GitHub page and click the "Fork" button. It's just that simple. Once you've done that, you can use your favorite git client to clone your repo or j

@jiggneshhgohel
jiggneshhgohel / gist:ade2c57d03c4ad895e82
Created February 27, 2015 21:26
Adobe Air 2.6 Installation Steps on Ubuntu 14.04 (64-bit)
@DrLulz
DrLulz / anki_html.py
Last active April 14, 2021 16:15
Grab Q/A from HTML source and create Anki Cards directly.
#!/usr/local/bin/python
import os
import sys
import csv
from operator import itemgetter
from bs4 import BeautifulSoup
from anki import Collection as aopen
usmle_rx = open("/Users/drlulz/Desktop/test.html",'r').read()
@noamross
noamross / base_r_plotting_tutorial_koontz_d-rug.r
Created April 24, 2015 17:34
Back to basics: High quality plots using base R graphics
### Title: Back to basics: High quality plots using base R graphics
### An interactive tutorial for the Davis R Users Group meeting on April 24, 2015
###
### Date created: 20150418
### Last updated: 20150423
###
### Author: Michael Koontz
### Email: mikoontz@gmail.com
### Twitter: @michaeljkoontz
###
@patperu
patperu / GET_Immoscout24.R
Last active June 24, 2022 09:01
Receive data from the ImmobilienScout24-API
library(httr)
library(jsonlite)
library(tidyverse)
# Keys, but it's better to set up
# environment variables via 'Sys.setenv'
consumerKey <- "aaa"
consumerSecret <- "bbb"
immo24_app <- oauth_app(appname = "app",
#install.packages('ReporteRs')
library('ReporteRs') # Load ReporteRs Package
pres.builder <- pptx(template = '.../Master.pptx')
pres.filename <- ".../R-Meetup_Output.pptx"
# Show slide names
pres.builder
# Build Title slide
pres.builder <- addSlide( pres.builder, "Title slide" ,bookmark = 1) # Slide name='Title slide', bookmark=1 <- overwrites first slide
D3 Links
--------
https://d3js.org/
https://bost.ocks.org/mike/bar/
https://jsfiddle.net/tLgp7qvv/ -> skalierender Bar Chart (abgewandelt von Teil 2 des Tutorials)
Javascript testen
-----------------
https://jsfiddle.net/