layout | title | shortbio | blob | isinterview | photo |
---|---|---|---|---|---|
interview |
Your Name goes here |
What do you do for a living (in 5-6 words!) |
Two to three sentences about what you do, and the tools you use |
true |
#Who are you and what do you do?
layout.foodweb = function(w, tlfunc = min, ...) | |
{ | |
# Who is a primary producer ? | |
PrimProd = (degree(w,mode='out') == 0) | |
# Get trophic level | |
fullSP = shortest.paths(w) | |
SP = shortest.paths(w,V(w)[ names(PrimProd[!PrimProd]) ],V(w)[ names(PrimProd[PrimProd]) ]) | |
V(w)[ names(PrimProd[PrimProd]) ]$y = 0 | |
LE = apply(SP,1, tlfunc, ...) | |
for(i in c(1:length(LE))){ |
## PyLogis | |
import numpy as np | |
import scipy as sp | |
import matplotlib.pyplot as plt | |
# Param orders: r, K | |
def logis(x, y, p): | |
est = [] |
\documentclass{beamer} | |
\usepackage{bera,berasans,beramono} | |
\usepackage{minted} | |
\usemintedstyle{colorful} | |
\begin{document} | |
\begin{frame}[fragile]{Code}{Test in Python} |
sort garbage.txt | uniq -u |
\documentclass{minimal} | |
\usepackage[T1]{fontenc} | |
\usepackage[utf8]{inputenc} | |
\usepackage[default,scale=0.95]{opensans} | |
\usepackage{mathastext} | |
\usepackage{pgfplots} | |
\usepgfplotslibrary{external} |
layout | title | shortbio | blob | isinterview | photo |
---|---|---|---|---|---|
interview |
Your Name goes here |
What do you do for a living (in 5-6 words!) |
Two to three sentences about what you do, and the tools you use |
true |
#Who are you and what do you do?
import networkx as nx | |
import scipy as sp | |
import numpy as np | |
import matplotlib.pyplot as plt | |
import community | |
def removeNode(web,node): | |
tempWeb = nx.DiGraph() | |
tempWeb.add_nodes_from(web.nodes()) |
import networkx as nx | |
import numpy as np | |
import scipy as sp | |
from scipy import stats | |
import matplotlib.pyplot as plt | |
import progressbar as pb # Get it from http://code.google.com/p/python-progressbar/ | |
import community # Get it from http://perso.crans.org/aynaud/communities/ | |
def nullModel(graph): | |
""" |
def niche_foodweb(S, C): | |
G = nx.DiGraph() | |
G.add_nodes_from([n for n in xrange(S)]) | |
## Step 1 - create random species | |
for n in G: | |
G.node[n]['n'] = np.round(np.random.uniform(),2) | |
G.node[n]['r'] = np.random.beta(1, 1/float(2*C)-1) * G.node[n]['n'] | |
G.node[n]['c'] = np.random.uniform(G.node[n]['r']/float(2),G.node[n]['n']) | |
## Step 2 - smallest species are basal | |
Smallest = np.min([G.node[n]['n'] for n in G]) |
// gcc niche.c -o nm -lgsl -lgslcblas -O3 -DHAVE_INLINE | |
// clang niche.c -o nm -lgsl -lgslcblas -O3 -DHAVE_INLINE | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <math.h> | |
#include <time.h> | |
#include <string.h> | |
#include <gsl/gsl_rng.h> | |
#include <gsl/gsl_randist.h> |