Skip to content

Instantly share code, notes, and snippets.

View jlaw9's full-sized avatar

Jeff Law jlaw9

View GitHub Profile
@jlaw9
jlaw9 / 250220_ecoli_k12_o157.ipynb
Last active May 22, 2025 20:38
Ecoli k12, o157 proteome comparison
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jlaw9
jlaw9 / Grid_sampling_simple_JL.ipynb
Created March 4, 2025 22:09
Code to sample points from a distribution using an evenly spaced grid. The grid is rotated along the principal axis, and each point of the grid is matched to the closest datapoint, if there is one within a specific radius
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jlaw9
jlaw9 / 20240517_fit_curves.ipynb
Last active May 20, 2024 18:39
Code for automatically parsing results from OpenTrons experiments
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jlaw9
jlaw9 / matminer-example.ipynb
Created October 4, 2022 22:31
Matminer example
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jlaw9
jlaw9 / permute_sparse_matrix.py
Last active November 13, 2020 20:42 — forked from vtraag/permute_sparse_matrix.py
Permute sparse matrix in Python using scipy COO format
from scipy import sparse
def permute_sparse_matrix(M, row_order=None, col_order=None):
"""
Reorders the rows and/or columns in a scipy sparse matrix to the specified order.
"""
if row_order is None and col_order is None:
return M
new_M = M